Subject: | test.flac fails tests (Audio::File::Tag does not support array values) |
test.flac included in the distribution fails tests.
When Audio::FLAC::Header encounters a file with multiple tags of the same type, it adds them
to an arrayref and returns said arrayref when queried. Audio::File does not handle this case.
Example:
test.flac has 4 tags for 'TRACKTOTAL'
When Audio::File::Flac::Tag tries to store the TRACKTOTAL value, it is storing an arrayref:
`$self->total( $flactag->{TRACKTOTAL} );`
Calling $file->tags->total is actually returning "$self->{total} + 0;", which returns the decimal
representation of memory address of the arrayref instead of the total number of tracks.
Suggestion would be to return last element in scalar context and the array in array context.