File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -165,7 +165,7 @@ - (NSDictionary *)constantsToExport
165165 fileContent = [[NSData alloc ] initWithData: [data dataUsingEncoding: NSUTF8StringEncoding allowLossyConversion: YES ]];
166166 }
167167 else if ([[encoding lowercaseString ] isEqualToString: @" base64" ]) {
168- fileContent = [[NSData alloc ] initWithBase64EncodedData: data options: 0 ];
168+ fileContent = [[NSData alloc ] initWithBase64EncodedData: data options: NSDataBase64DecodingIgnoreUnknownCharacters ];
169169 }
170170 else if ([[encoding lowercaseString ] isEqualToString: @" uri" ]) {
171171 NSString * orgPath = [data stringByReplacingOccurrencesOfString: FILE_PREFIX withString: @" " ];
@@ -639,7 +639,12 @@ - (NSDictionary *)constantsToExport
639639- (UIViewController *) documentInteractionControllerViewControllerForPreview : (UIDocumentInteractionController *) controller
640640{
641641 UIWindow *window = [UIApplication sharedApplication ].keyWindow ;
642- return window.rootViewController ;
642+ UIViewController *currentlyPresentedView = [window.rootViewController presentedViewController ];
643+ if (currentlyPresentedView == nil )
644+ {
645+ return window.rootViewController ;
646+ }
647+ return currentlyPresentedView;
643648}
644649
645650# pragma mark - check expired network events
Original file line number Diff line number Diff line change @@ -41,6 +41,7 @@ class RNFetchBlobFetchPolyfill {
4141 promise = Blob . build ( body ) . then ( ( b ) => {
4242 blobCache = b
4343 options . headers [ 'Content-Type' ] = 'multipart/form-data;boundary=' + b . multipartBoundary
44+ options . headers [ 'content-type' ] = 'multipart/form-data;boundary=' + b . multipartBoundary
4445 return Promise . resolve ( RNFetchBlob . wrap ( b . _ref ) )
4546 } )
4647 }
You can’t perform that action at this time.
0 commit comments