dartexif icon indicating copy to clipboard operation
dartexif copied to clipboard

readExifFromBytes & readExifFromFile are marked as Async but are technically Sync function

Open PapyElGringo opened this issue 3 years ago • 1 comments

Future<Map<String, IfdTag>> readExifFromBytes(List<int> bytes,
    {String? stopTag,
    bool details = true,
    bool strict = false,
    bool debug = false,
    bool truncateTags = true}) async {
  return readExifFromFileReader(FileReader.fromBytes(bytes),
          stopTag: stopTag,
          details: details,
          strict: strict,
          debug: debug,
          truncateTags: truncateTags)
      .tags;
}

Since readExifFromFileReader is a sync function readExifFromBytes should be too. It's currently make us believe that there is some async process running

PapyElGringo avatar Jun 30 '22 08:06 PapyElGringo

you're right.
I'll consider it in the next release.

bigflood avatar Jul 02 '22 02:07 bigflood