flutter_luban icon indicating copy to clipboard operation
flutter_luban copied to clipboard

List<dynamic> is not a sub-type of type List<String>

Open Okiring opened this issue 3 years ago • 1 comments

static List<String?> _lubanCompressList(List<CompressObject> objects) { var results = []; objects.forEach((_o) { results.add(_lubanCompress(_o)); }); return results as List<String?>; }

The above method was causing that error: Had to change to the below and resolved the error

static List<String?> _lubanCompressList(List<CompressObject> objects) { var results = []; objects.forEach((_o) { results.add(_lubanCompress(_o)); }); return (results as List<dynamic?>).cast<String?>(); }

Okiring avatar Jan 19 '22 17:01 Okiring

@crazecoder compressImageList is not working, it needs this quick fix.

icnahom avatar Apr 18 '22 18:04 icnahom