Browse Source

fix avatar

marinofaggiana 4 năm trước cách đây
mục cha
commit
72546343d3

+ 1 - 5
iOSClient/Settings/CCManageAccount.m

@@ -74,11 +74,7 @@
         } else {
         } else {
             
             
             UIImage *image = [UIImage imageNamed:@"avatarCredentials"];
             UIImage *image = [UIImage imageNamed:@"avatarCredentials"];
-            UIGraphicsBeginImageContextWithOptions(CGSizeMake(35, 35), NO, 0.0);
-            [image drawInRect:CGRectMake(0, 0, 35, 35)];
-            UIImage *newImage = UIGraphicsGetImageFromCurrentImageContext();
-            UIGraphicsEndImageContext();
-            avatar = newImage;
+            avatar = [image imageWithColor:NCBrandColor.shared.icon size:35];
         }
         }
         
         
         row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundCell;
         row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundCell;