diff --git a/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdMultiSideRecognizerSerialization.java b/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdMultiSideRecognizerSerialization.java index 20274cb..970c520 100644 --- a/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdMultiSideRecognizerSerialization.java +++ b/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdMultiSideRecognizerSerialization.java @@ -67,7 +67,9 @@ public JSONObject serializeResult(Recognizer recognizer) { jsonResult.put("expired", result.isExpired()); jsonResult.put("faceImage", SerializationUtils.encodeImageBase64(result.getFaceImage())); jsonResult.put("faceImageLocation", SerializationUtils.serializeRectangle(result.getFaceImageLocation())); - jsonResult.put("faceImageSide", SerializationUtils.serializeEnum(result.getFaceImageSide())); + if (result.getFaceImageSide() != null) { + jsonResult.put("faceImageSide", SerializationUtils.serializeEnum(result.getFaceImageSide())); + } jsonResult.put("fathersName", BlinkIDSerializationUtils.serializeStringResult(result.getFathersName())); jsonResult.put("firstName", BlinkIDSerializationUtils.serializeStringResult(result.getFirstName())); jsonResult.put("frontAdditionalProcessingInfo", BlinkIDSerializationUtils.serializeAdditionalProcessingInfo(result.getFrontAdditionalProcessingInfo())); diff --git a/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdSingleSideRecognizerSerialization.java b/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdSingleSideRecognizerSerialization.java index a321add..3c3e878 100644 --- a/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdSingleSideRecognizerSerialization.java +++ b/BlinkID/src/android/java/com/microblink/blinkid/plugins/cordova/recognizers/serialization/BlinkIdSingleSideRecognizerSerialization.java @@ -60,7 +60,9 @@ public JSONObject serializeResult(Recognizer recognizer) { jsonResult.put("expired", result.isExpired()); jsonResult.put("faceImage", SerializationUtils.encodeImageBase64(result.getFaceImage())); jsonResult.put("faceImageLocation", SerializationUtils.serializeRectangle(result.getFaceImageLocation())); - jsonResult.put("faceImageSide", SerializationUtils.serializeEnum(result.getFaceImageSide())); + if (result.getFaceImageSide() != null) { + jsonResult.put("faceImageSide", SerializationUtils.serializeEnum(result.getFaceImageSide())); + } jsonResult.put("fathersName", BlinkIDSerializationUtils.serializeStringResult(result.getFathersName())); jsonResult.put("firstName", BlinkIDSerializationUtils.serializeStringResult(result.getFirstName())); jsonResult.put("fullDocumentImage", SerializationUtils.encodeImageBase64(result.getFullDocumentImage())); diff --git a/BlinkID/www/blinkIdScanner.js b/BlinkID/www/blinkIdScanner.js index b9762bc..e78b8cd 100644 --- a/BlinkID/www/blinkIdScanner.js +++ b/BlinkID/www/blinkIdScanner.js @@ -2593,7 +2593,7 @@ function BlinkIdMultiSideRecognizerResult(nativeResult) { /** * Detailed info on data match. */ - this.dataMatchResult = nativeResult.dataMatchResult; + this.dataMatch = nativeResult.dataMatch; /** * The date of birth of the document owner.