handled test mode when getting FirstName

git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/workspace-tree-widget@141361 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Francesco Mangiacrapa 2016-12-22 10:34:59 +00:00
parent c905902b5d
commit 2cec1d1c25
1 changed files with 3 additions and 0 deletions

View File

@ -2663,6 +2663,9 @@ public class GWTWorkspaceServiceImpl extends RemoteServiceServlet implements GWT
*/
@Override
public String getMyFirstName(){
if(!isWithinPortal())
return "";
PortalContextInfo info = WsUtil.getPortalContext(this.getThreadLocalRequest());
String username = info.getUsername();
String firstName = "";