diff options
author | Cheng-Han, Wu | 2016-05-16 13:54:00 +0800 |
---|---|---|
committer | Cheng-Han, Wu | 2016-05-16 13:54:00 +0800 |
commit | 5bb4423309ddfd3a161c3ec2472e79067125553e (patch) | |
tree | 9502440ed863c0f8017156ac3bb1b25bf7a2ca6d /public/js | |
parent | c8560ec5fbd346cd6d73375af3f69a31463a10f5 (diff) |
Fix to handle if last change user profile photo is null
Diffstat (limited to 'public/js')
-rw-r--r-- | public/js/extra.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/public/js/extra.js b/public/js/extra.js index fd9fba6b..79364d11 100644 --- a/public/js/extra.js +++ b/public/js/extra.js @@ -30,7 +30,8 @@ function updateLastChangeUser() { if (lastchangeuser && lastchangeuserprofile) { var icon = lastchangeui.user.children('i'); icon.attr('title', lastchangeuserprofile.name).tooltip('fixTitle'); - icon.attr('style', 'background-image:url(' + lastchangeuserprofile.photo + ')'); + if (lastchangeuserprofile.photo) + icon.attr('style', 'background-image:url(' + lastchangeuserprofile.photo + ')'); lastchangeui.user.show(); lastchangeui.nouser.hide(); } else { |