Fix displaying retina avatars smaller than 128px
authorMatthias Schmidt <gravatronics@live.com>
Thu, 16 Apr 2015 17:00:26 +0000 (19:00 +0200)
committerMatthias Schmidt <gravatronics@live.com>
Thu, 16 Apr 2015 17:00:26 +0000 (19:00 +0200)
wcfsetup/install/files/lib/data/user/avatar/UserAvatar.class.php

index 17b7b66e2bf9253f7f3d49e9d61bab86259f8656..05f232297c4e834ed356e3b7676682ca2ebbec7d 100644 (file)
@@ -130,7 +130,9 @@ class UserAvatar extends DatabaseObject implements IUserAvatar {
                        
                        case 64:
                        case 96:
-                               $retinaSize = 128;
+                               if ($this->size >= 128 && $this->height >= 128) {
+                                       $retinaSize = 128;
+                               }
                        break;
                }