aboutsummaryrefslogtreecommitdiffstats
path: root/core/src/jquery/avatar.js
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/jquery/avatar.js')
-rw-r--r--core/src/jquery/avatar.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/core/src/jquery/avatar.js b/core/src/jquery/avatar.js
index eaedce1461b..24cef392d34 100644
--- a/core/src/jquery/avatar.js
+++ b/core/src/jquery/avatar.js
@@ -65,7 +65,7 @@ import OC from '../OC'
*/
$.fn.avatar = function(user, size, ie8fix, hidedefault, callback, displayname) {
- var setAvatarForUnknownUser = function(target) {
+ const setAvatarForUnknownUser = function(target) {
target.imageplaceholder('?')
target.css('background-color', '#b9b9b9')
}
@@ -102,8 +102,8 @@ $.fn.avatar = function(user, size, ie8fix, hidedefault, callback, displayname) {
// sanitize
user = String(user).replace(/\//g, '')
- var $div = this
- var url
+ const $div = this
+ let url
// If this is our own avatar we have to use the version attribute
if (user === OC.getCurrentUser().uid) {
@@ -112,18 +112,18 @@ $.fn.avatar = function(user, size, ie8fix, hidedefault, callback, displayname) {
{
user: user,
size: Math.ceil(size * window.devicePixelRatio),
- version: oc_userconfig.avatar.version
+ version: oc_userconfig.avatar.version,
})
} else {
url = OC.generateUrl(
'/avatar/{user}/{size}',
{
user: user,
- size: Math.ceil(size * window.devicePixelRatio)
+ size: Math.ceil(size * window.devicePixelRatio),
})
}
- var img = new Image()
+ const img = new Image()
// If the new image loads successfully set it.
img.onload = function() {