Skip to content
Snippets Groups Projects
Commit dbeb3710 authored by Tom Gross's avatar Tom Gross
Browse files

Simplify creation of name for display in footer

parent dd30dbae
No related branches found
No related tags found
No related merge requests found
...@@ -116,13 +116,11 @@ public class OlatFooterController extends BasicController implements LockableCon ...@@ -116,13 +116,11 @@ public class OlatFooterController extends BasicController implements LockableCon
// Push information about user // Push information about user
if (!isGuest && usess.isAuthenticated()) { if (!isGuest && usess.isAuthenticated()) {
olatFootervc.contextPut("loggedIn", Boolean.TRUE); olatFootervc.contextPut("loggedIn", Boolean.TRUE);
if(isInvitee) { String fullName = StringHelper.escapeHtml(CoreSpringFactory.getImpl(UserManager.class).getUserDisplayName(ureq.getIdentity()));
String fullName = CoreSpringFactory.getImpl(UserManager.class).getUserDisplayName(ureq.getIdentity()); if (isInvitee) {
olatFootervc.contextPut("username", StringHelper.escapeHtml(fullName) + " " + translate("logged.in.invitee")); fullName = fullName + " " + translate("logged.in.invitee");
} else {
String fullName = CoreSpringFactory.getImpl(UserManager.class).getUserDisplayName(ureq.getIdentity());
olatFootervc.contextPut("username", StringHelper.escapeHtml(fullName));
} }
olatFootervc.contextPut("username", fullName);
} else { } else {
olatFootervc.contextPut("loggedIn", Boolean.FALSE); olatFootervc.contextPut("loggedIn", Boolean.FALSE);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment