Skip to content

Commit

Permalink
Fixing app restarting on disabling service
Browse files Browse the repository at this point in the history
  • Loading branch information
aandrew-me committed Mar 12, 2023
1 parent 717e859 commit 2887d8c
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@ void stopAlarm() {
service.invoke("stopAlarm");
final FlutterLocalNotificationsPlugin flutterLocalNotificationsPlugin =
FlutterLocalNotificationsPlugin();

flutterLocalNotificationsPlugin.cancelAll();

// Rebuild UI
restartApp();
}
Expand Down Expand Up @@ -73,7 +70,6 @@ Future<void> initializeService() async {

void onDidReceiveNotificationResponse(
NotificationResponse notificationResponse) async {
stopAlarm();
print("Clicked on notification");
}

Expand Down

0 comments on commit 2887d8c

Please sign in to comment.