Skip to content

Commit

Permalink
Fix CodeCollector tests
Browse files Browse the repository at this point in the history
onDetect adds its own listener, but it’s no longer used!
  • Loading branch information
backspace committed Sep 19, 2024
1 parent a053862 commit 346fe82
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion waydowntown_app/lib/games/code_collector.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ class CodeCollectorGame extends StatelessWidget {
height: 300,
child: MobileScanner(
controller: (detector as CodeDetector).controller,
onDetect: (capture) {},
),
),
),
Expand All @@ -41,6 +40,7 @@ class CodeCollectorGame extends StatelessWidget {
class CodeDetector implements StringDetector {
final MobileScannerController controller;
final _detectedCodesController = StreamController<String>.broadcast();
StreamSubscription? _barcodesSubscription;

CodeDetector(MobileScannerController? scannerController)
: controller = scannerController ?? MobileScannerController();
Expand Down

0 comments on commit 346fe82

Please sign in to comment.