Fixed HasPrimaryImage on DTOBaseItem

This commit is contained in:
LukePulverenti Luke Pulverenti luke pulverenti 2012-09-02 17:55:47 -04:00
parent e4b0eb5779
commit 9baf40becb

View File

@ -41,14 +41,14 @@ namespace MediaBrowser.Api
tasks.Add(AttachPeople(dto, item));
}
AttachBasicFields(dto, item, user);
// Make sure all the tasks we kicked off have completed.
if (tasks.Count > 0)
{
await Task.WhenAll(tasks).ConfigureAwait(false);
}
AttachBasicFields(dto, item, user);
return dto;
}
@ -67,7 +67,7 @@ namespace MediaBrowser.Api
dto.HasArt = !string.IsNullOrEmpty(item.ArtImagePath);
dto.HasBanner = !string.IsNullOrEmpty(item.BannerImagePath);
dto.HasLogo = !string.IsNullOrEmpty(item.LogoImagePath);
dto.HasPrimaryImage = !string.IsNullOrEmpty(item.LogoImagePath);
dto.HasPrimaryImage = !string.IsNullOrEmpty(item.PrimaryImagePath);
dto.HasThumb = !string.IsNullOrEmpty(item.ThumbnailImagePath);
dto.Id = item.Id;
dto.IsNew = item.IsRecentlyAdded(user);