Fixed NullPointerException in PicassoProvider

This commit is contained in:
daniel oeh 2014-08-01 11:49:12 +02:00
parent 09c4736867
commit 988b327efe
1 changed files with 5 additions and 1 deletions

View File

@ -127,7 +127,11 @@ public class PicassoProvider {
mmr.setDataSource(uri.getPath());
byte[] data = mmr.getEmbeddedPicture();
mmr.release();
return new Response(new ByteArrayInputStream(data), true, data.length);
if (data != null) {
return new Response(new ByteArrayInputStream(data), true, data.length);
} else {
return null;
}
}
}