facia-mobilesdk 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ios/MobilesdkModule.m +15 -10
- package/package.json +1 -1
package/ios/MobilesdkModule.m
CHANGED
|
@@ -25,22 +25,27 @@ RCT_EXPORT_METHOD(verify:(NSString *)documentType config:(NSString *)config call
|
|
|
25
25
|
UIViewController* vc = RCTPresentedViewController();
|
|
26
26
|
|
|
27
27
|
|
|
28
|
+
if ([documentType caseInsensitiveCompare:@"ID_CARD"] == NSOrderedSame) {
|
|
29
|
+
|
|
30
|
+
config[@"documentType"] = @(DocumentTypeID_CARD);
|
|
31
|
+
|
|
32
|
+
} else if ([documentType caseInsensitiveCompare:@"PASSPORT"] == NSOrderedSame) {
|
|
33
|
+
|
|
34
|
+
config[@"documentType"] = @(DocumentTypePASSPORT);
|
|
35
|
+
|
|
36
|
+
} else {
|
|
37
|
+
|
|
38
|
+
config[@"documentType"] = @(DocumentTypeOTHERS);
|
|
39
|
+
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
|
|
28
43
|
[facia createRequestWithParentViewController:vc
|
|
29
44
|
configs:[self parseJSONString:config]
|
|
30
45
|
completion:^(NSDictionary *result) {
|
|
31
46
|
NSString *response = [self convertToJSONString:result];
|
|
32
47
|
callback(@[response]);
|
|
33
48
|
}];
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
// [shufti shuftiProVerificationWithRequestObject:[self parseJSONString:request] authKeys:[self parseJSONString:auth] parentVC:vc configs:[self parseJSONString:config] completion:^(NSDictionary *result) {
|
|
37
|
-
// NSLog(@"Verification completed. Result: %@", result);
|
|
38
|
-
// NSString *response = [self convertToJSONString:result];
|
|
39
|
-
|
|
40
|
-
// callback(@[response]);
|
|
41
|
-
// }];
|
|
42
|
-
|
|
43
|
-
|
|
44
49
|
}
|
|
45
50
|
|
|
46
51
|
|