diff --git a/CHANGELOG.md b/CHANGELOG.md index 5e98d6b..8799159 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## 4.0.1 + +* Fix error that it can't find File.length() method at web. + ## 4.0.0 * Migrate to 3.16.0 diff --git a/lib/src/_platform_web.dart b/lib/src/_platform_web.dart index dc98a52..8d7b829 100644 --- a/lib/src/_platform_web.dart +++ b/lib/src/_platform_web.dart @@ -22,6 +22,13 @@ class File { /// is the contents of the file. Future readAsBytes() async => Uint8List.fromList([]); + /// The length of the file. + /// + /// Returns a `Future` that completes with the length in bytes. + Future length() async { + return 0; + } + /// The path of the file underlying this random access file. final String path; } diff --git a/pubspec.yaml b/pubspec.yaml index 1192404..960443a 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: extended_image_library description: package library for extended_image, extended_text and extended_text_field, provide common base class. -version: 4.0.0 +version: 4.0.1 homepage: https://github.com/fluttercandies/extended_image_library environment: