Skip to content

Commit 516cb87

Browse files
committed
Added Named Parameter formats to analyzeImage method of MobileScanner Controller
1 parent 8d6907f commit 516cb87

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/src/mobile_scanner_controller.dart

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,10 @@ class MobileScannerController extends ValueNotifier<MobileScannerState> {
193193
///
194194
/// If an error occurred during the analysis of the image,
195195
/// a [MobileScannerBarcodeException] error is thrown.
196-
Future<BarcodeCapture?> analyzeImage(String path) {
197-
return MobileScannerPlatform.instance.analyzeImage(path);
196+
Future<BarcodeCapture?> analyzeImage(String path, {
197+
List<BarcodeFormat> formats = const <BarcodeFormat>[],
198+
}) {
199+
return MobileScannerPlatform.instance.analyzeImage(path,formats: formats);
198200
}
199201

200202
/// Build a camera preview widget.

0 commit comments

Comments
 (0)