iOS: Fix Crash when CameraRoll is getting assets from iCloud and no filename is provided. #13671
Summary: RCTCameraRollManager.m crashes when there is no filename provided for the asset (usually from iCloud). #13671 Tested on real device with iCloud library using the library without and after my fix. It worked after my changes. [IOS] [BUGFIX] [CameraRoll] - Changed the filename if nil to be empty when the asset is coming from iCloud. Closes https://github.com/facebook/react-native/pull/17549 Differential Revision: D6710665 Pulled By: hramos fbshipit-source-id: 319865b0a71728798c62ee380e7bee4af584b3e3
This commit is contained in:
parent
c04c1e2674
commit
33525fcc98
|
@ -199,7 +199,7 @@ RCT_EXPORT_METHOD(getPhotos:(NSDictionary *)params
|
|||
@"group_name": [group valueForProperty:ALAssetsGroupPropertyName],
|
||||
@"image": @{
|
||||
@"uri": uri,
|
||||
@"filename" : filename,
|
||||
@"filename" : filename ?: [NSNull null],
|
||||
@"height": @(dimensions.height),
|
||||
@"width": @(dimensions.width),
|
||||
@"isStored": @YES,
|
||||
|
|
Loading…
Reference in New Issue