@@ -238,13 +238,13 @@ - (void)hideView:(CDVInvokedUrlCommand *)command {
238
238
// Assign new hide callback
239
239
self.hideViewCallbackId = command.callbackId ;
240
240
241
- NSDictionary *options;
241
+ NSDictionary *options = NULL ;
242
242
if ([command.arguments count ] > 0 ) {
243
243
// Assign options
244
244
options = [command.arguments objectAtIndex: 1 ];
245
245
}
246
246
247
- if (options) {
247
+ if (![ options isKindOfClass: [ NSNull class ]] ) {
248
248
NSDictionary *animationDict = [options objectForKey: @" animation" ];
249
249
if (animationDict) {
250
250
NSString *type = [animationDict objectForKey: @" type" ];
@@ -356,12 +356,12 @@ - (void)showView:(CDVInvokedUrlCommand *)command {
356
356
// Assign new show callback
357
357
self.showViewCallbackId = command.callbackId ;
358
358
359
- NSDictionary *options;
359
+ NSDictionary *options = NULL ;
360
360
if ([command.arguments count ] > 0 ) {
361
361
// Assign options
362
362
options = [command.arguments objectAtIndex: 1 ];
363
363
}
364
- if (options) {
364
+ if (![ options isKindOfClass: [ NSNull class ]] ) {
365
365
NSDictionary * animationDict = [options objectForKey: @" animation" ];
366
366
if (animationDict) {
367
367
@@ -453,14 +453,14 @@ - (void)load:(CDVInvokedUrlCommand *)command {
453
453
// assign arguments
454
454
NSString *viewName = [command.arguments objectAtIndex: 0 ];
455
455
456
- NSDictionary * options;
456
+ NSDictionary * options = NULL ;
457
457
if ([command.arguments count ] > 0 ) {
458
458
options = [command.arguments objectAtIndex: 1 ];
459
459
}
460
460
461
461
WizLog (@" [WizCanvasPlugin] ******* Load into canvas : %@ - viewlist -> %@ options %@ " , viewName, wizViewList, options);
462
462
463
- if (options) {
463
+ if (![ options isKindOfClass: [ NSNull class ]] ) {
464
464
// Find the correct view
465
465
if ([wizViewList objectForKey: viewName]) {
466
466
0 commit comments