Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
小 白蛋
Intellij Community
Commits
80d988db
Commit
80d988db
authored
8 years ago
by
Valentina Kiryushkina
Browse files
Options
Download
Email Patches
Plain Diff
Do not show user name and surname if they're null or empty
parent
3e93150f
Branches unavailable
Tags unavailable
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
python/educational-core/src/com/jetbrains/edu/learning/ui/StudyStepicUserWidget.java
+9
-1
.../com/jetbrains/edu/learning/ui/StudyStepicUserWidget.java
with
9 additions
and
1 deletion
+9
-1
python/educational-core/src/com/jetbrains/edu/learning/ui/StudyStepicUserWidget.java
+
9
-
1
View file @
80d988db
...
...
@@ -96,7 +96,15 @@ public class StudyStepicUserWidget implements IconLikeCustomStatusBarWidget {
createUserPanel
(
"You're not logged in"
,
"Authorize on Stepik"
,
createAuthorizeUserListener
());
}
else
{
String
statusText
=
"<html>You're logged in as <i>"
+
user
.
getFirstName
()
+
" "
+
user
.
getLastName
()
+
"</i></html>"
;
String
firstName
=
user
.
getFirstName
();
String
lastName
=
user
.
getLastName
();
String
statusText
;
if
(
firstName
==
null
||
lastName
==
null
||
firstName
.
isEmpty
()
||
lastName
.
isEmpty
())
{
statusText
=
"You're logged in"
;
}
else
{
statusText
=
"<html>You're logged in as <i>"
+
firstName
+
" "
+
lastName
+
"</i></html>"
;
}
createUserPanel
(
statusText
,
"Log out"
,
createLogoutListener
());
}
}
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help