update polymer

This commit is contained in:
Luke Pulverenti
2015-07-23 22:48:10 -04:00
parent ba9ed26c4a
commit 609d2283c6
9 changed files with 166 additions and 35 deletions

View File

@@ -194,6 +194,15 @@ namespace MediaBrowser.Providers.Manager
return updateType;
}
protected async Task SaveItem(MetadataResult<TItemType> result, ItemUpdateType reason, CancellationToken cancellationToken)
{
if (result.Item.SupportsPeople && result.People != null)
{
await LibraryManager.UpdatePeople(result.Item as BaseItem, result.People.ToList());
}
await result.Item.UpdateToRepository(reason, cancellationToken).ConfigureAwait(false);
}
private readonly Task _cachedTask = Task.FromResult(true);
protected virtual Task AfterMetadataRefresh(TItemType item, MetadataRefreshOptions refreshOptions, CancellationToken cancellationToken)
{
@@ -328,15 +337,6 @@ namespace MediaBrowser.Providers.Manager
return providers;
}
protected async Task SaveItem(MetadataResult<TItemType> result, ItemUpdateType reason, CancellationToken cancellationToken)
{
if (result.Item.SupportsPeople)
{
await LibraryManager.UpdatePeople(result.Item as BaseItem, result.People);
}
await result.Item.UpdateToRepository(reason, cancellationToken).ConfigureAwait(false);
}
public bool CanRefresh(IHasMetadata item)
{
return item is TItemType;