Be explicit about backgroundImage existance
This commit is contained in:
@@ -379,7 +379,8 @@ angular.module('Application').service('Client', ['$http', '$interval', '$timeout
|
||||
email: null,
|
||||
twoFactorAuthenticationEnabled: false,
|
||||
source: null,
|
||||
avatarUrl: null
|
||||
avatarUrl: null,
|
||||
hasBackgroundImage: false
|
||||
};
|
||||
this._config = {
|
||||
consoleServerOrigin: null,
|
||||
@@ -508,6 +509,7 @@ angular.module('Application').service('Client', ['$http', '$interval', '$timeout
|
||||
this._userInfo.role = userInfo.role;
|
||||
this._userInfo.source = userInfo.source;
|
||||
this._userInfo.avatarUrl = userInfo.avatarUrl + '?s=128&default=mp&ts=' + Date.now(); // we add the timestamp to avoid caching
|
||||
this._userInfo.hasBackgroundImage = userInfo.hasBackgroundImage;
|
||||
this._userInfo.isAtLeastOwner = [ ROLES.OWNER ].indexOf(userInfo.role) !== -1;
|
||||
this._userInfo.isAtLeastAdmin = [ ROLES.OWNER, ROLES.ADMIN ].indexOf(userInfo.role) !== -1;
|
||||
this._userInfo.isAtLeastMailManager = [ ROLES.OWNER, ROLES.ADMIN, ROLES.MAIL_MANAGER ].indexOf(userInfo.role) !== -1;
|
||||
|
||||
Reference in New Issue
Block a user