CB-8351 Use argumentForIndex rather than NSArray extension

This commit is contained in:
Andrew Grieve 2015-01-23 09:49:21 -05:00
parent eb119e7180
commit cad3a13c37

View File

@ -232,7 +232,7 @@ static const void *kStatusBarStyle = &kStatusBarStyle;
- (void) overlaysWebView:(CDVInvokedUrlCommand*)command - (void) overlaysWebView:(CDVInvokedUrlCommand*)command
{ {
id value = [command.arguments objectAtIndex:0]; id value = [command argumentAtIndex:0];
if (!([value isKindOfClass:[NSNumber class]])) { if (!([value isKindOfClass:[NSNumber class]])) {
value = [NSNumber numberWithBool:YES]; value = [NSNumber numberWithBool:YES];
} }
@ -301,7 +301,7 @@ static const void *kStatusBarStyle = &kStatusBarStyle;
- (void) backgroundColorByName:(CDVInvokedUrlCommand*)command - (void) backgroundColorByName:(CDVInvokedUrlCommand*)command
{ {
id value = [command.arguments objectAtIndex:0]; id value = [command argumentAtIndex:0];
if (!([value isKindOfClass:[NSString class]])) { if (!([value isKindOfClass:[NSString class]])) {
value = @"black"; value = @"black";
} }
@ -325,7 +325,7 @@ static const void *kStatusBarStyle = &kStatusBarStyle;
- (void) backgroundColorByHexString:(CDVInvokedUrlCommand*)command - (void) backgroundColorByHexString:(CDVInvokedUrlCommand*)command
{ {
NSString* value = [command.arguments objectAtIndex:0]; NSString* value = [command argumentAtIndex:0];
if (!([value isKindOfClass:[NSString class]])) { if (!([value isKindOfClass:[NSString class]])) {
value = @"#000000"; value = @"#000000";
} }