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

fix: Android 15 runtime error in HomeWidgetLaunchIntent #324

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

Conversation

StuartCameron98
Copy link

Description

Current Android 15 is failing due to pendingIntentBackgroundActivityStartMode being initialized prematurely. After taking this line out the the run time error in getActivity no longer fires.

Checklist

  • I have updated/added tests for ALL new/updated/fixed functionality.
  • I have updated/added relevant documentation and added code (documentation) comments where necessary.
  • I have updated/added relevant examples in example or documentation.

Breaking Change?

  • Yes, this PR is a breaking change.
  • No, this PR is not a breaking change.

Related Issues

…n of pendingIntentBackgroundActivityStartMode
Copy link

docs-page bot commented Jan 8, 2025

To view this pull requests documentation preview, visit the following URL:

docs.page/abausg/home_widget~324

Documentation is deployed and generated using docs.page.

Comment on lines -36 to -37
options.pendingIntentBackgroundActivityStartMode =
ActivityOptions.MODE_BACKGROUND_ACTIVITY_START_ALLOWED
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add an if statement around this so this is only executed on Android Version <15

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