Skip to content

Commit 97a774f

Browse files
lorenzomilesichristopherdro
authored andcommitted
Clear options (#70)
1 parent d8e9e5f commit 97a774f

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

ios/RNPrint/RNPrint.m

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,17 @@ - (dispatch_queue_t)methodQueue
1717
RCT_EXPORT_METHOD(print:(NSDictionary *)options
1818
resolver:(RCTPromiseResolveBlock)resolve
1919
rejecter:(RCTPromiseRejectBlock)reject) {
20-
20+
2121
if (options[@"filePath"]){
2222
_filePath = [RCTConvert NSString:options[@"filePath"]];
23+
} else {
24+
_filePath = nil;
2325
}
2426

2527
if (options[@"html"]){
2628
_htmlString = [RCTConvert NSString:options[@"html"]];
29+
} else {
30+
_htmlString = nil;
2731
}
2832

2933
if (options[@"printerURL"]){

0 commit comments

Comments
 (0)