The method scanBytes works fine with images that have some QR Code to analyze, but if you scan something without any QR Code the plugin doesn't returns the error. Using Visual Studio Code, I can see on Debug Console the message W/System.err(27635): com.google.zxing.NotFoundException. Unfortunatelly, the error can't be catched inside a try/catch block or catchError of the Future.
The current solution is return all errors catched by onAnalyzeFailed even if errorCode was equals to null, because the method onAnalyzeFailed is called when any error occurs.
Error com.google.zxing.NotFoundException
Platform Android
Flutter 1.22.5
Dart 2.10.4
The method
scanBytes
works fine with images that have some QR Code to analyze, but if you scan something without any QR Code the plugin doesn't returns the error. Using Visual Studio Code, I can see on Debug Console the messageW/System.err(27635): com.google.zxing.NotFoundException
. Unfortunatelly, the error can't be catched inside atry/catch
block orcatchError
of the Future.The current solution is return all errors catched by
onAnalyzeFailed
even iferrorCode
was equals to null, because the methodonAnalyzeFailed
is called when any error occurs.