From 79ab5c83c0402cae91de690ccb68fb46ec625bb9 Mon Sep 17 00:00:00 2001 From: leca Date: Sun, 20 Oct 2024 16:02:47 +0300 Subject: [PATCH] fixed persisted scan state on scan cancelling --- .../activities/AddAbstractProductActivity.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/org/foxarmy/barcodescannerforemployees/activities/AddAbstractProductActivity.kt b/app/src/main/java/org/foxarmy/barcodescannerforemployees/activities/AddAbstractProductActivity.kt index b06022c..369ea4f 100644 --- a/app/src/main/java/org/foxarmy/barcodescannerforemployees/activities/AddAbstractProductActivity.kt +++ b/app/src/main/java/org/foxarmy/barcodescannerforemployees/activities/AddAbstractProductActivity.kt @@ -307,11 +307,11 @@ class AddAbstractProductActivity : AppCompatActivity() { if (result.contents == null) { Toast.makeText(this, getString(R.string.cancelled), Toast.LENGTH_SHORT).show() } else { - scanningBarcode = false val scannedBarcode = result.contents barcodeText.setText(scannedBarcode) performRequest(scannedBarcode) } + scanningBarcode = false } }