Skip to content

Commit

Permalink
Added Named Parameter formats to analyzeI
Browse files Browse the repository at this point in the history
mage method of MobileScanner Controller
  • Loading branch information
abhiaggoel committed Oct 14, 2024
1 parent 8d6907f commit 76077df
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/src/mobile_scanner_controller.dart
Original file line number Diff line number Diff line change
Expand Up @@ -193,8 +193,11 @@ class MobileScannerController extends ValueNotifier<MobileScannerState> {
///
/// If an error occurred during the analysis of the image,
/// a [MobileScannerBarcodeException] error is thrown.
Future<BarcodeCapture?> analyzeImage(String path) {
return MobileScannerPlatform.instance.analyzeImage(path);
Future<BarcodeCapture?> analyzeImage(
String path, {
List<BarcodeFormat> formats = const <BarcodeFormat>[],
}) {
return MobileScannerPlatform.instance.analyzeImage(path,formats: formats);
}

/// Build a camera preview widget.
Expand Down

0 comments on commit 76077df

Please sign in to comment.