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 potential UnsupportedOperationException #400

Merged
merged 2 commits into from
May 29, 2019

Conversation

marverenic
Copy link
Collaborator

Fixes #165954849.

This PR fixes an issue where setting the queue as an unmodifiable list (like the list of all songs) might cause an UnsupportedOperationException to be thrown if another component got a reference to the list and attempted to modify it.

Testing Steps

  1. Open app as usual
  2. Make sure shuffle is disabled
  3. Choose any song from Songs tab
  4. Open the queue and try to rearrange any of the songs in the list
  5. The app will crash with UnsupportedOperationException

Fixes an issue where setting the queue as an unmodifiable list (like the list of all songs) might cause an UnsupportedOperationException to be thrown if another component got a reference to the list and attempted to modify it.

An example of when this happens is if you play all songs in the library and reorder an item in the queue from the now playing page.
@marverenic marverenic merged commit def314d into master May 29, 2019
@marverenic marverenic deleted the m/immutable-list-crash branch May 29, 2019 01:55
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.

None yet

2 participants