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 media activity crash on menu item visibility change #460

Merged
merged 1 commit into from
Dec 23, 2021

Conversation

wax911
Copy link
Member

@wax911 wax911 commented Dec 23, 2021

AniTrend Pull Request

Thank you for contributing! Please take a moment to review our contributing guidelines
to make the process easy and effective for everyone involved.

Please open an issue before embarking on any significant pull request, especially those that
add a new library or change existing tests, otherwise you risk spending a lot of time working
on something that might not end up being merged into the project.

Before opening a pull request, please ensure:

  • You have followed our contributing guidelines
  • double-check your branch is based on develop and targets develop
  • Pull request has tests
  • Code is well-commented, linted and follows project conventions
  • Documentation is updated (if necessary)
  • Description explains the issue/use-case resolved
  • I did not commit files that are excluded in the .gitignore file (Happens if you stage files with Android Studio)

Description

Fixes a crash that would happen when trying to access the

  • Renames setManageMenuItemIcon to setMenuItemIcons
  • Moves malMenuItem into setMenuItemIcons and perform null-ability check on menu item prior to making any changes

Motivation and Context

See linked issue.

How Has This Been Tested?

Checks MenuItem null-ability prior to making changes

Screenshots (if appropriate):

n/a

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

IMPORTANT: By submitting a patch, you agree to allow the project
owners to license your work under the terms of the MIT License.

Closes #458

- Renames `setManageMenuItemIcon` to `setMenuItemIcons`
- Moves `malMenuItem` into `setMenuItemIcons` and perform null-ability check on menu item prior to making any changes
@wax911 wax911 added the bug Broken functionality label Dec 23, 2021
@wax911 wax911 self-assigned this Dec 23, 2021
@wax911 wax911 linked an issue Dec 23, 2021 that may be closed by this pull request
Copy link
Member

@luk1337 luk1337 left a comment

Choose a reason for hiding this comment

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

Works fine, also makes MAL icon show up at the same time as other icons.

@wax911 wax911 merged commit d652854 into release/1.9.6 Dec 23, 2021
@wax911 wax911 deleted the hotfix/458-crash-in-media-activity branch December 23, 2021 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Broken functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Null pointer exception: Crash on MediaActivity
3 participants