You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by sh...@apache.org on 2015/03/19 01:11:54 UTC

ios commit: CB-7767 - Remove usage of NSData+Base64

Repository: cordova-ios
Updated Branches:
  refs/heads/4.0.x a65420bef -> 4f1ccbe55


CB-7767 - Remove usage of NSData+Base64


Project: http://git-wip-us.apache.org/repos/asf/cordova-ios/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-ios/commit/4f1ccbe5
Tree: http://git-wip-us.apache.org/repos/asf/cordova-ios/tree/4f1ccbe5
Diff: http://git-wip-us.apache.org/repos/asf/cordova-ios/diff/4f1ccbe5

Branch: refs/heads/4.0.x
Commit: 4f1ccbe55bef4c36cc2ea746ca405b39fa5ec07a
Parents: a65420b
Author: Shazron Abdullah <sh...@apache.org>
Authored: Wed Mar 18 17:11:55 2015 -0700
Committer: Shazron Abdullah <sh...@apache.org>
Committed: Wed Mar 18 17:11:55 2015 -0700

----------------------------------------------------------------------
 CordovaLib/Classes/Public/CDVInvokedUrlCommand.m | 3 +--
 CordovaLib/Classes/Public/CDVPluginResult.m      | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/4f1ccbe5/CordovaLib/Classes/Public/CDVInvokedUrlCommand.m
----------------------------------------------------------------------
diff --git a/CordovaLib/Classes/Public/CDVInvokedUrlCommand.m b/CordovaLib/Classes/Public/CDVInvokedUrlCommand.m
index 3a5e8e7..5b4281d 100644
--- a/CordovaLib/Classes/Public/CDVInvokedUrlCommand.m
+++ b/CordovaLib/Classes/Public/CDVInvokedUrlCommand.m
@@ -19,7 +19,6 @@
 
 #import "CDVInvokedUrlCommand.h"
 #import "CDVJSON_private.h"
-#import "NSData+Base64.h"
 
 @implementation CDVInvokedUrlCommand
 
@@ -85,7 +84,7 @@
             newArgs = [NSMutableArray arrayWithArray:_arguments];
             _arguments = newArgs;
         }
-        [newArgs replaceObjectAtIndex:i withObject:[NSData cdv_dataFromBase64String:data]];
+        [newArgs replaceObjectAtIndex:i withObject:[[NSData alloc] initWithBase64EncodedString:data options:0]];
     }
 }
 

http://git-wip-us.apache.org/repos/asf/cordova-ios/blob/4f1ccbe5/CordovaLib/Classes/Public/CDVPluginResult.m
----------------------------------------------------------------------
diff --git a/CordovaLib/Classes/Public/CDVPluginResult.m b/CordovaLib/Classes/Public/CDVPluginResult.m
index f200c04..b7a185d 100644
--- a/CordovaLib/Classes/Public/CDVPluginResult.m
+++ b/CordovaLib/Classes/Public/CDVPluginResult.m
@@ -20,7 +20,6 @@
 #import "CDVPluginResult.h"
 #import "CDVJSON_private.h"
 #import "CDVDebug.h"
-#import "NSData+Base64.h"
 
 @interface CDVPluginResult ()
 
@@ -37,7 +36,7 @@ id messageFromArrayBuffer(NSData* data)
 {
     return @{
                @"CDVType" : @"ArrayBuffer",
-               @"data" :[data cdv_base64EncodedString]
+               @"data" :[data base64EncodedStringWithOptions:0]
     };
 }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org