From e19e6e888aa3408022d1ada3e2a8f435088b929e Mon Sep 17 00:00:00 2001 From: Alex Li Date: Tue, 19 Mar 2024 14:13:14 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=F0=9F=90=9B=20Fix=20ignore=20locks=20when?= =?UTF-8?q?=20exception=20throws?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/src/states/camera_picker_state.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/states/camera_picker_state.dart b/lib/src/states/camera_picker_state.dart index fb9bc66..906d683 100644 --- a/lib/src/states/camera_picker_state.dart +++ b/lib/src/states/camera_picker_state.dart @@ -334,7 +334,7 @@ class CameraPickerState extends State return initializeLock!.future; } final lock = ignoreLocks ? initializeLock! : Completer(); - if (ignoreLocks) { + if (lock != initializeLock) { initializeLock = lock; } Future(() async { From ac81872ad549f07db06cac1da6eb8253e60ad570 Mon Sep 17 00:00:00 2001 From: Alex Li Date: Tue, 19 Mar 2024 14:14:16 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=94=96=204.2.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 6 ++++++ example/pubspec.yaml | 2 +- pubspec.yaml | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 96d1588..69ab610 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,12 @@ that can be found in the LICENSE file. --> See the [Migration Guide](guides/migration_guide.md) for breaking changes between versions. +## 4.2.1 + +### Fixes + +- Fix ignore locks when exception throws. + ## 4.2.0 ### Breaking changes diff --git a/example/pubspec.yaml b/example/pubspec.yaml index ee8f3d8..b1f9145 100644 --- a/example/pubspec.yaml +++ b/example/pubspec.yaml @@ -1,6 +1,6 @@ name: wechat_camera_picker_demo description: A new Flutter project. -version: 4.2.0+32 +version: 4.2.1+33 publish_to: none environment: diff --git a/pubspec.yaml b/pubspec.yaml index 4d313e7..8ad66d4 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,5 +1,5 @@ name: wechat_camera_picker -version: 4.2.0 +version: 4.2.1 description: | A camera picker for Flutter projects based on WeChat's UI, which is also a separate runnable extension to the