Fix possible crash when trying to delete a genre

This commit is contained in:
Karim Abou Zeid 2017-12-31 15:36:41 +01:00
commit 95bc75b2bf

View file

@ -37,7 +37,8 @@ public class GenreLoader {
// try to remove the empty genre from the media store // try to remove the empty genre from the media store
try { try {
context.getContentResolver().delete(Genres.EXTERNAL_CONTENT_URI, Genres._ID + " == " + genre.id, null); context.getContentResolver().delete(Genres.EXTERNAL_CONTENT_URI, Genres._ID + " == " + genre.id, null);
} catch (IllegalArgumentException | UnsupportedOperationException ignored) { } catch (Exception e) {
e.printStackTrace();
// nothing we can do then // nothing we can do then
} }
} }