diff options
author | Morris Jobke <hey@morrisjobke.de> | 2016-03-17 17:34:22 +0100 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2016-03-18 08:59:47 +0100 |
commit | 1179462f4edf44e4cf84cc8e2ccbce5288cd8721 (patch) | |
tree | 4aaa3553b1e16f45fede8503d117e3b14749f23d /settings | |
parent | 7e92ef37e3006f9b1e71ef13284038c22faa1a12 (diff) | |
download | nextcloud-server-1179462f4edf44e4cf84cc8e2ccbce5288cd8721.tar.gz nextcloud-server-1179462f4edf44e4cf84cc8e2ccbce5288cd8721.zip |
Update avatar on username change if avatar is set
* fixes #20455
Diffstat (limited to 'settings')
-rw-r--r-- | settings/js/personal.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/settings/js/personal.js b/settings/js/personal.js index 3439eba686f..4eeb5c3b39b 100644 --- a/settings/js/personal.js +++ b/settings/js/personal.js @@ -75,7 +75,10 @@ function changeDisplayName () { $('#oldDisplayName').val($('#displayName').val()); // update displayName on the top right expand button $('#expandDisplayName').text($('#displayName').val()); - updateAvatar(); + // update avatar if avatar is available + if($('#removeavatar').css('display') !== 'none') { + updateAvatar(); + } } else { $('#newdisplayname').val(data.data.displayName); |