SwiftGS1Barcode icon indicating copy to clipboard operation
SwiftGS1Barcode copied to clipboard

Processing twice each ai... is that how it is supposed to work?

Open MagnoUrbano opened this issue 3 years ago • 2 comments

Hi

I turn printDebugOutput to true on GS1BarcodeParser.swift.

When this method parseGS1ApplicationIdentifier(ai:data:) runs, I get duplicate printings on console, like this

Parsing application identifier with identifier 01 of type Optional("AlphaNumeric")
Parsing application identifier with identifier 17 of type Optional("Date")
Parsing application identifier with identifier 10 of type Optional("AlphaNumeric")
Parsing application identifier with identifier 21 of type Optional("AlphaNumeric")
Parsing application identifier with identifier 01 of type Optional("AlphaNumeric")
Parsing application identifier with identifier 17 of type Optional("Date")
Parsing application identifier with identifier 10 of type Optional("AlphaNumeric")
Parsing application identifier with identifier 21 of type Optional("AlphaNumeric")

The library is parsing identifiers 1, 17, 10 and 21 two times and for some barcodes, it crashes after this.

Is it supposed to do this?

thanks

MagnoUrbano avatar Mar 10 '21 10:03 MagnoUrbano