Closed Alt791350 closed 3 years ago
I was able to reproduce the error message. It seems that only PRIORITY_DEFAULT
, PRIORITY_HIGH
and PRIORITY_MAX
are valid priority levels when creating the notification channel for a foreground service notification, even though the documentation claims otherwise 🤔
I think the fix would be to just remove the two invalid options. What do you think?
Can this notice be hidden
I was testing some of my code and noticed this error when initializing for the very first time (when you just installed the app and initializing for the first time).
The full error:
So I wrote some test code to make sure it is just this package and not a conflict with something or other code I wrote wrong.
AndroidNotificationImportance.Low
andAndroidNotificationImportance.Min
throw bothInvalid importance level
. The error gets thrown whenawait FlutterBackground.enableBackgroundExecution();
is executed when the permissions gets accepted for the first time. Starting the app with the permission already accepted throws no error for anyAndroidNotificationImportance
level.