From f409ad4af59a1250b743e4b2215e00804c721aa2 Mon Sep 17 00:00:00 2001 From: Ben Walch Date: Sun, 25 Apr 2021 13:14:06 +0200 Subject: [PATCH] fix and simplify bundle resource path --- Source/AssetManager.swift | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Source/AssetManager.swift b/Source/AssetManager.swift index edb6e52d..de10998b 100644 --- a/Source/AssetManager.swift +++ b/Source/AssetManager.swift @@ -4,10 +4,7 @@ import Photos extension Bundle { static func myResourceBundle() -> Bundle? { - let bundles = Bundle.allBundles - let bundlePaths = bundles.compactMap { $0.resourceURL?.appendingPathComponent("ImagePicker", isDirectory: false).appendingPathExtension("bundle") } - - return bundlePaths.compactMap({ Bundle(url: $0) }).first + return Bundle(for: ImagePickerController.self) } }