Don't crash for null songs
This commit is contained in:
parent
4634dd8ca5
commit
4495daf234
@ -314,6 +314,9 @@ public final class CoverView extends View implements Handler.Callback {
|
|||||||
*/
|
*/
|
||||||
private void generateBitmap(Song song)
|
private void generateBitmap(Song song)
|
||||||
{
|
{
|
||||||
|
if (song == null)
|
||||||
|
return;
|
||||||
|
|
||||||
Bitmap bitmap = mBitmapCache.get(song.id);
|
Bitmap bitmap = mBitmapCache.get(song.id);
|
||||||
if (bitmap == null) {
|
if (bitmap == null) {
|
||||||
bitmap = mBitmapCache.discardOldest();
|
bitmap = mBitmapCache.discardOldest();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user