set DontFetchMeta at resolve time

pull/702/head
Luke Pulverenti 11 years ago
parent 4c230f7901
commit fb4c559549

@ -155,19 +155,7 @@ namespace MediaBrowser.Controller.Entities
/// Returns true if this item should not attempt to fetch metadata
/// </summary>
/// <value><c>true</c> if [dont fetch meta]; otherwise, <c>false</c>.</value>
[IgnoreDataMember]
public virtual bool DontFetchMeta
{
get
{
if (Path != null)
{
return Path.IndexOf("[dontfetchmeta]", StringComparison.OrdinalIgnoreCase) != -1;
}
return false;
}
}
public bool DontFetchMeta { get; set; }
/// <summary>
/// Determines whether the item has a saved local image of the specified name (jpg or png).

@ -1,9 +1,10 @@
using MediaBrowser.Common.Extensions;
using MediaBrowser.Controller.Entities;
using MediaBrowser.Controller.Library;
using MediaBrowser.Controller.Resolvers;
using System;
using System.IO;
using System.Text.RegularExpressions;
using MediaBrowser.Controller.Resolvers;
namespace MediaBrowser.Server.Implementations.Library
{
@ -39,6 +40,8 @@ namespace MediaBrowser.Server.Implementations.Library
// Make sure the item has a name
EnsureName(item);
item.DontFetchMeta = item.Path.IndexOf("[dontfetchmeta]", StringComparison.OrdinalIgnoreCase) != -1;
// Make sure DateCreated and DateModified have values
EntityResolutionHelper.EnsureDates(item, args);
}

Loading…
Cancel
Save