react-native-okhi 1.2.18-beta.1 → 1.2.18-beta.2
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/android/build.gradle +2 -2
- package/android/src/main/java/com/reactnativeokhi/OkhiModule.java +10 -2
- package/lib/commonjs/OkCollect/app.json +1 -1
- package/lib/module/OkCollect/app.json +1 -1
- package/package.json +1 -1
- package/react-native-okhi.podspec +1 -1
- package/src/OkCollect/app.json +1 -1
package/android/build.gradle
CHANGED
|
@@ -126,8 +126,8 @@ repositories {
|
|
|
126
126
|
dependencies {
|
|
127
127
|
//noinspection GradleDynamicVersion
|
|
128
128
|
implementation "com.facebook.react:react-native:+"
|
|
129
|
-
implementation 'io.okhi.android:core:1.7.
|
|
130
|
-
implementation 'io.okhi.android:okverify:1.9.
|
|
129
|
+
implementation 'io.okhi.android:core:1.7.23'
|
|
130
|
+
implementation 'io.okhi.android:okverify:1.9.48'
|
|
131
131
|
// From node_modules
|
|
132
132
|
}
|
|
133
133
|
|
|
@@ -34,6 +34,7 @@ import io.okhi.android_core.models.OkHiException;
|
|
|
34
34
|
import io.okhi.android_core.models.OkHiLocation;
|
|
35
35
|
import io.okhi.android_core.models.OkHiPermissionService;
|
|
36
36
|
import io.okhi.android_core.models.OkHiUser;
|
|
37
|
+
import io.okhi.android_core.models.OkHiVerificationType;
|
|
37
38
|
import io.okhi.android_core.models.OkPreference;
|
|
38
39
|
import io.okhi.android_okverify.OkVerify;
|
|
39
40
|
import io.okhi.android_okverify.interfaces.OkVerifyCallback;
|
|
@@ -200,8 +201,15 @@ public class OkhiModule extends ReactContextBaseJavaModule {
|
|
|
200
201
|
return;
|
|
201
202
|
}
|
|
202
203
|
OkHiUser user = new OkHiUser.Builder(phoneNumber).build();
|
|
203
|
-
|
|
204
|
-
|
|
204
|
+
String[] verificationTypesList = new String[verificationTypes.size()];
|
|
205
|
+
for (int i = 0; i < verificationTypes.size(); i++) {
|
|
206
|
+
verificationTypesList[i] = verificationTypes.getString(i);
|
|
207
|
+
}
|
|
208
|
+
if (verificationTypesList.length == 0) {
|
|
209
|
+
verificationTypesList = new String[]{OkHiVerificationType.digital.name()};
|
|
210
|
+
}
|
|
211
|
+
OkHiLocation location = new OkHiLocation.Builder(locationId, lat, lon).setVerificationTypes(verificationTypesList).build();
|
|
212
|
+
okVerify.start(user, location, new OkVerifyCallback<String>() {
|
|
205
213
|
@Override
|
|
206
214
|
public void onSuccess(String result) {
|
|
207
215
|
promise.resolve(result);
|
package/package.json
CHANGED
|
@@ -17,7 +17,7 @@ Pod::Spec.new do |s|
|
|
|
17
17
|
s.source_files = "ios/**/*.{h,m,mm,swift}"
|
|
18
18
|
|
|
19
19
|
s.dependency "React-Core"
|
|
20
|
-
s.dependency "OkHi", "1.9.
|
|
20
|
+
s.dependency "OkHi", "1.9.38"
|
|
21
21
|
|
|
22
22
|
# Don't install the dependencies when we run `pod install` in the old architecture.
|
|
23
23
|
if ENV['RCT_NEW_ARCH_ENABLED'] == '1' then
|
package/src/OkCollect/app.json
CHANGED