Skip to content

Commit

Permalink
Fix type warnings and simplify code with auto boxing.
Browse files Browse the repository at this point in the history
  • Loading branch information
PlanetaryCode authored and dpogue committed Apr 18, 2020
1 parent fb49478 commit 755484b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CordovaLib/Classes/Public/CDVPluginResult.m
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ - (CDVPluginResult*)initWithStatus:(CDVCommandStatus)statusOrdinal message:(id)t
{
self = [super init];
if (self) {
status = [NSNumber numberWithInt:statusOrdinal];
status = @(statusOrdinal);
message = theMessage;
keepCallback = [NSNumber numberWithBool:NO];
}
Expand Down
2 changes: 1 addition & 1 deletion CordovaLib/Classes/Public/CDVViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,7 @@ - (UIInterfaceOrientationMask)supportedInterfaceOrientations

- (BOOL)supportsOrientation:(UIInterfaceOrientation)orientation
{
return [self.supportedOrientations containsObject:[NSNumber numberWithInt:orientation]];
return [self.supportedOrientations containsObject:@(orientation)];
}

- (UIView*)newCordovaViewWithFrame:(CGRect)bounds
Expand Down

0 comments on commit 755484b

Please sign in to comment.