aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2013-10-13 21:09:42 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2013-10-13 21:09:42 -0400
commitbef67412b15cc0210d9d2c4c7b174691d3049fd7 (patch)
tree21c22a6faf0ad6b22a0bf2f91fc346c994b1585e /MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs
parent559acbc074af03456ffe32f4b98900e2ef8af8a1 (diff)
run fast people providers during library scan to pick up images quicker
Diffstat (limited to 'MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs')
-rw-r--r--MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs b/MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs
index 88f0e1e22..cfc7f4310 100644
--- a/MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs
+++ b/MediaBrowser.Server.Implementations/Library/Validators/PeoplePostScanTask.cs
@@ -41,12 +41,10 @@ namespace MediaBrowser.Server.Implementations.Library.Validators
/// <returns>Task.</returns>
public Task Run(IProgress<double> progress, CancellationToken cancellationToken)
{
- RunInternal(progress, cancellationToken);
-
- return Task.FromResult(true);
+ return RunInternal(progress, cancellationToken);
}
- private void RunInternal(IProgress<double> progress, CancellationToken cancellationToken)
+ private async Task RunInternal(IProgress<double> progress, CancellationToken cancellationToken)
{
var userLibraries = _userManager.Users
.Select(i => new Tuple<Guid, IList<BaseItem>>(i.Id, i.RootFolder.GetRecursiveChildren(i, null)))
@@ -90,6 +88,8 @@ namespace MediaBrowser.Server.Implementations.Library.Validators
var itemByName = _libraryManager.GetPerson(name);
+ await itemByName.RefreshMetadata(cancellationToken, allowSlowProviders: false).ConfigureAwait(false);
+
foreach (var libraryId in counts.Keys)
{
var itemCounts = CountHelpers.GetCounts(counts[libraryId]);