diff --git a/dashboard/src/js/client.js b/dashboard/src/js/client.js index 42b28709f..388d58421 100644 --- a/dashboard/src/js/client.js +++ b/dashboard/src/js/client.js @@ -2522,7 +2522,7 @@ angular.module('Application').service('Client', ['$http', '$interval', '$timeout }); }; - Client.prototype.refreshUserInfo = function (callback) { + Client.prototype.refreshProfile = function (callback) { var that = this; callback = typeof callback === 'function' ? callback : function () {}; diff --git a/dashboard/src/js/index.js b/dashboard/src/js/index.js index aec2585f3..5e1c09512 100644 --- a/dashboard/src/js/index.js +++ b/dashboard/src/js/index.js @@ -787,7 +787,7 @@ app.controller('MainController', ['$scope', '$route', '$timeout', '$location', ' // get user profile as the first thing. this populates the "scope" and affects subsequent API calls async.series([ - Client.refreshUserInfo.bind(Client), + Client.refreshProfile.bind(Client), Client.refreshConfig.bind(Client), Client.refreshAvailableLanguages.bind(Client), Client.refreshInstalledApps.bind(Client) diff --git a/dashboard/src/views/profile.js b/dashboard/src/views/profile.js index d37e08d14..2b7ca1d01 100644 --- a/dashboard/src/views/profile.js +++ b/dashboard/src/views/profile.js @@ -101,7 +101,7 @@ angular.module('Application').controller('ProfileController', ['$scope', '$trans return; } - Client.refreshUserInfo(); + Client.refreshProfile(); $('#twoFactorAuthenticationEnableModal').modal('hide'); }); @@ -123,7 +123,7 @@ angular.module('Application').controller('ProfileController', ['$scope', '$trans return; } - Client.refreshUserInfo(); + Client.refreshProfile(); $('#twoFactorAuthenticationDisableModal').modal('hide'); }); @@ -180,7 +180,7 @@ angular.module('Application').controller('ProfileController', ['$scope', '$trans function done(error) { if (error) return console.error('Unable to change avatar.', error); - Client.refreshUserInfo(function (error) { + Client.refreshProfile(function (error) { if (error) return console.error(error); $('#avatarChangeModal').modal('hide'); @@ -394,7 +394,7 @@ angular.module('Application').controller('ProfileController', ['$scope', '$trans return; } - Client.refreshUserInfo(); + Client.refreshProfile(); $scope.emailChange.reset(); $('#emailChangeModal').modal('hide'); @@ -452,7 +452,7 @@ angular.module('Application').controller('ProfileController', ['$scope', '$trans } // update user info in the background - Client.refreshUserInfo(); + Client.refreshProfile(); $scope.fallbackEmailChange.reset(); $('#fallbackEmailChangeModal').modal('hide'); @@ -600,7 +600,7 @@ angular.module('Application').controller('ProfileController', ['$scope', '$trans } // update user info in the background - Client.refreshUserInfo(); + Client.refreshProfile(); $scope.displayNameChange.reset(); $('#displayNameChangeModal').modal('hide'); @@ -702,7 +702,7 @@ angular.module('Application').controller('ProfileController', ['$scope', '$trans Client.onReady(function () { $scope.appPassword.refresh(); $scope.tokens.refresh(); - Client.refreshUserInfo(); // 2fa status might have changed by admin + Client.refreshProfile(); // 2fa status might have changed by admin $translate.onReady(function () { var usedLang = $translate.use() || $translate.fallbackLanguage();