File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -860,7 +860,13 @@ + (BOOL)requiresMainQueueSetup
860860 // __block NSURL* videoURL = [NSURL URLWithString:destination];
861861 __block NSError *error = nil ;
862862
863- PHFetchResult *phAssetFetchResult = [PHAsset fetchAssetsWithALAssetURLs: @[url] options: nil ];
863+ PHFetchResult *phAssetFetchResult = nil ;
864+ if ([url.scheme isEqualToString: @" ph" ]) {
865+ phAssetFetchResult = [PHAsset fetchAssetsWithLocalIdentifiers: @[[imageUri substringFromIndex: 5 ]] options: nil ];
866+ } else {
867+ phAssetFetchResult = [PHAsset fetchAssetsWithALAssetURLs: @[url] options: nil ];
868+ }
869+
864870 PHAsset *phAsset = [phAssetFetchResult firstObject ];
865871
866872 PHVideoRequestOptions *options = [[PHVideoRequestOptions alloc ] init ];
You can’t perform that action at this time.
0 commit comments