Fixed null Uri issue when playing adds

Checks for null Uri before attempting to read it
This commit is contained in:
cory_shivers 2015-07-14 00:05:16 -05:00
parent 55505a008e
commit 9158518994

View File

@ -28,8 +28,9 @@ namespace SpotifyAPI.Local.Models
/// <returns>A String, which is the URL to the Albumart</returns>
public String GetAlbumArtUrl(AlbumArtSize size)
{
if (AlbumResource.Uri.Contains("local"))
if (AlbumResource.Uri == null || AlbumResource.Uri.Contains("local"))
return "";
int albumsize = 0;
switch (size)
{