Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[flutter_local_notifications] solves the expected behavior for 'didNotificationLaunchApp' #2150

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mdAlvarenga
Copy link

@mdAlvarenga mdAlvarenga commented Nov 8, 2023

Condition added to avoid 'didNotificationLaunchApp=true' when opening app from recent apps list in Android.
Related to #1926
By @LeoTDev & @ximena-bogado

Condition added to avoid 'didNotificationLaunchApp=true' when opening app from recent apps list.
@MaikuB
Copy link
Owner

MaikuB commented Jan 13, 2024

Thanks for the PR. Unfortunately this introduces an issue where on Android, subsequent calls to getNotificationAppLaunchDetails() returns information to indicate that the app wasn't launched from a notification and this would happen even if the app wasn't put in the background and resumed later on. This results in inconsistent behaviour on iOS and macOS. The approach used by you used seems to be to essentially consume the notification once read. If this is to be done, then I would say that the PR should change to make this a behaviour that the user can opt-into e.g. update getNotificationAppLaunchDetails() to take a consumeNotification boolean argument and implement the expected behaviour on all the supported platforms. Is this something you can do as part of the PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants