From d10f4c0bd81561413e5516e23aba9e43345fcf67 Mon Sep 17 00:00:00 2001 From: Jenkins Date: Fri, 31 Mar 2023 18:09:43 +0300 Subject: [PATCH] 6.7.4 --- example/package.json | 2 +- package.json | 2 +- plugin.xml | 2 +- src/android/DocumentReader.java | 7 ++----- src/ios/RGLWJSONConstructor.m | 2 +- 5 files changed, 6 insertions(+), 9 deletions(-) diff --git a/example/package.json b/example/package.json index e85bb84..cf0b3be 100644 --- a/example/package.json +++ b/example/package.json @@ -16,7 +16,7 @@ "cordova-android": "^10.1.1", "cordova-ios": "^6.2.0", "cordova-plugin-add-swift-support": "^2.0.2", - "@regulaforensics/cordova-plugin-document-reader-api": "6.7.3", + "@regulaforensics/cordova-plugin-document-reader-api": "6.7.4", "@regulaforensics/cordova-plugin-document-reader-core-fullrfid": "6.7.0", "cordova-plugin-file": "^6.0.2", "cordova-plugin-telerik-imagepicker": "^2.3.5", diff --git a/package.json b/package.json index 203341d..a83abe0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@regulaforensics/cordova-plugin-document-reader-api", - "version": "6.7.3", + "version": "6.7.4", "description": "Cordova plugin for reading and validation of identification documents (API framework)", "cordova": { "id": "@regulaforensics/cordova-plugin-document-reader-api", diff --git a/plugin.xml b/plugin.xml index 0f2ea2e..07a9eb5 100644 --- a/plugin.xml +++ b/plugin.xml @@ -1,5 +1,5 @@ - DocumentReaderApi Cordova plugin Document reader api diff --git a/src/android/DocumentReader.java b/src/android/DocumentReader.java index d05b990..d242b2c 100644 --- a/src/android/DocumentReader.java +++ b/src/android/DocumentReader.java @@ -464,11 +464,8 @@ private void startForegroundDispatch(final Activity activity) { new String[]{"android.nfc.tech.IsoDep"} }; Intent intent = new Intent(activity.getApplicationContext(), activity.getClass()); - intent.setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP); - int flags = 0; - if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) - flags = PendingIntent.FLAG_IMMUTABLE; - PendingIntent pendingIntent = PendingIntent.getActivity(activity.getApplicationContext(), 0, intent, flags); + int flag = Build.VERSION.SDK_INT >= Build.VERSION_CODES.S ? PendingIntent.FLAG_MUTABLE : 0; + PendingIntent pendingIntent = PendingIntent.getActivity(activity.getApplicationContext(), 0, intent, flag); NfcAdapter.getDefaultAdapter(getActivity()).enableForegroundDispatch(activity, pendingIntent, filters, techList); } diff --git a/src/ios/RGLWJSONConstructor.m b/src/ios/RGLWJSONConstructor.m index d905e7f..cde2daf 100644 --- a/src/ios/RGLWJSONConstructor.m +++ b/src/ios/RGLWJSONConstructor.m @@ -201,7 +201,7 @@ +(NSMutableDictionary*)generateCompletion:(NSInteger)action :(RGLDocumentReaderR break; case 999: result[@"results"] = [self generateResultsWithRFID :results :1]; - action = 1; + action = 0; break; default: break;