mirror of
https://gitee.com/shuto/cordova-imagePicker.git
synced 2026-05-23 00:05:03 +08:00
based on options for outputType, add base64 encoded string or file_uri to resultStrings
This commit is contained in:
+5
-1
@@ -101,7 +101,11 @@ typedef enum : NSUInteger {
|
||||
result = [CDVPluginResult resultWithStatus:CDVCommandStatus_IO_EXCEPTION messageAsString:[err localizedDescription]];
|
||||
break;
|
||||
} else {
|
||||
[resultStrings addObject:[[NSURL fileURLWithPath:filePath] absoluteString]];
|
||||
if(self.outputType == BASE64_STRING){
|
||||
[resultStrings addObject:[data base64EncodedStringWithOptions:NSDataBase64Encoding64CharacterLineLength]];
|
||||
} else {
|
||||
[resultStrings addObject:[[NSURL fileURLWithPath:filePath] absoluteString]];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user