From ca8f6ee10bedf52dfbc8ae13590a5f89cac0faf0 Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Wed, 3 Jul 2019 10:08:59 -0400 Subject: [PATCH] FFImageLoading only for main app --- src/iOS.Core/Utilities/iOSCoreHelpers.cs | 11 ----------- src/iOS/AppDelegate.cs | 11 +++++++++++ 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/iOS.Core/Utilities/iOSCoreHelpers.cs b/src/iOS.Core/Utilities/iOSCoreHelpers.cs index 280bbc871..ce63d5a4b 100644 --- a/src/iOS.Core/Utilities/iOSCoreHelpers.cs +++ b/src/iOS.Core/Utilities/iOSCoreHelpers.cs @@ -44,17 +44,6 @@ namespace Bit.iOS.Core.Utilities ServiceContainer.Register("logService", new ConsoleLogService()); } - // Note: This might cause a race condition. Investigate more. - Task.Run(() => - { - FFImageLoading.Forms.Platform.CachedImageRenderer.Init(); - FFImageLoading.ImageService.Instance.Initialize(new FFImageLoading.Config.Configuration - { - FadeAnimationEnabled = false, - FadeAnimationForCachedImages = false - }); - }); - var preferencesStorage = new PreferencesStorageService(AppGroupId); var appGroupContainer = new NSFileManager().GetContainerUrl(AppGroupId); var liteDbStorage = new LiteDbStorageService( diff --git a/src/iOS/AppDelegate.cs b/src/iOS/AppDelegate.cs index 5129ff404..7057bd35d 100644 --- a/src/iOS/AppDelegate.cs +++ b/src/iOS/AppDelegate.cs @@ -246,6 +246,17 @@ namespace Bit.iOS "oldSecureStorageService", new Migration.KeyChainStorageService()); } + // Note: This might cause a race condition. Investigate more. + Task.Run(() => + { + FFImageLoading.Forms.Platform.CachedImageRenderer.Init(); + FFImageLoading.ImageService.Instance.Initialize(new FFImageLoading.Config.Configuration + { + FadeAnimationEnabled = false, + FadeAnimationForCachedImages = false + }); + }); + iOSCoreHelpers.RegisterLocalServices(); RegisterPush(); ServiceContainer.Init();