From 51e10bb6b3c462304e032a9d89cc9fd4b9f9e284 Mon Sep 17 00:00:00 2001 From: DonnieBLT <128622481+DonnieBLT@users.noreply.github.com> Date: Fri, 23 Feb 2024 23:39:56 -0500 Subject: [PATCH 1/4] Update build-flutter.yml Signed-off-by: DonnieBLT <128622481+DonnieBLT@users.noreply.github.com> --- .github/workflows/build-flutter.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-flutter.yml b/.github/workflows/build-flutter.yml index ab029e7cf1..c0e83dbd55 100644 --- a/.github/workflows/build-flutter.yml +++ b/.github/workflows/build-flutter.yml @@ -16,7 +16,7 @@ jobs: channel: 'stable' architecture: x64 - run: flutter pub get - - run: flutter analyze --no-fatal-infos + - run: flutter analyze - run: flutter build apk # Upload APK as a build artifact From f52819cf0afe53aa56f83a8c4d622d80422aa0d5 Mon Sep 17 00:00:00 2001 From: DonnieBLT <128622481+DonnieBLT@users.noreply.github.com> Date: Sat, 24 Feb 2024 01:05:48 -0500 Subject: [PATCH 2/4] Update build-flutter.yml --- .github/workflows/build-flutter.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-flutter.yml b/.github/workflows/build-flutter.yml index c0e83dbd55..9f02e88138 100644 --- a/.github/workflows/build-flutter.yml +++ b/.github/workflows/build-flutter.yml @@ -1,5 +1,5 @@ name: Build and Test Flutter App -on: [push] +on: [push, pull_request] jobs: test: From 7f1b2317de464e2b0be3d925f262f3ee4beffbbd Mon Sep 17 00:00:00 2001 From: DonnieBLT <128622481+DonnieBLT@users.noreply.github.com> Date: Sat, 24 Feb 2024 01:22:53 -0500 Subject: [PATCH 3/4] Update pubspec.yaml --- pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pubspec.yaml b/pubspec.yaml index 1874967c3a..6589de0d00 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,7 +1,7 @@ name: blt description: The BLT-Flutter App -version: 1.0.4+1 +version: 1.0.5+1 publish_to: none environment: From 27ac6a40940eebb38055e39f2fb23e64a72756e8 Mon Sep 17 00:00:00 2001 From: Parag Gupta <103507835+Dante291@users.noreply.github.com> Date: Sat, 24 Feb 2024 12:02:49 +0530 Subject: [PATCH 4/4] Fixing WillPopScope deprecated (#352) Co-authored-by: DonnieBLT <128622481+DonnieBLT@users.noreply.github.com> --- lib/src/pages/home/home.dart | 6 +++--- lib/src/pages/leaderboards/monthly_leaderboard.dart | 5 ++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/lib/src/pages/home/home.dart b/lib/src/pages/home/home.dart index 7b81386a10..96ad245b2c 100644 --- a/lib/src/pages/home/home.dart +++ b/lib/src/pages/home/home.dart @@ -211,8 +211,9 @@ class _HomeState extends ConsumerState { @override Widget build(BuildContext context) { - return WillPopScope( - onWillPop: () async { + return PopScope( + canPop: false, + onPopInvoked: (_) async { showGeneralDialog( context: context, barrierLabel: "Barrier", @@ -223,7 +224,6 @@ class _HomeState extends ConsumerState { return buildLogOUtDialog(); }, ); - return false; }, child: Scaffold( appBar: buildAppBar(context: context), diff --git a/lib/src/pages/leaderboards/monthly_leaderboard.dart b/lib/src/pages/leaderboards/monthly_leaderboard.dart index c0e1c5300d..9fafc88c09 100644 --- a/lib/src/pages/leaderboards/monthly_leaderboard.dart +++ b/lib/src/pages/leaderboards/monthly_leaderboard.dart @@ -75,13 +75,12 @@ class _MonthlyLeaderBoardPageState Widget build(BuildContext context) { final Size size = MediaQuery.of(context).size; final monthlyLeadersState = ref.watch(monthlyLeaderBoardProvider); - return WillPopScope( - onWillPop: () async { + return PopScope( + onPopInvoked: (_) async { ref .watch(monthlyLeaderBoardProvider.notifier) .refreshMonthlyLeaderList( DateTime.now().year, DateTime.now().month); - return true; }, child: Scaffold( appBar: AppBar(