1
0
Fork 0
mirror of https://github.com/lidarr/Lidarr synced 2024-12-26 17:47:08 +00:00

Updated file scan logging

This commit is contained in:
kay.one 2011-05-18 20:56:19 -07:00
parent 6d085d5340
commit b4ea8838d2
2 changed files with 6 additions and 5 deletions

View file

@ -27,10 +27,10 @@ public class EpisodeParseResult
public override string ToString()
{
if (Episodes == null)
return string.Format("Series:{0} Air Date:{1}", CleanTitle, AirDate.Date);
return string.Format("{0} - {1}", CleanTitle, AirDate.Date);
return string.Format("Series:{0} Season:{1} Episode:{2}", CleanTitle, SeasonNumber,
String.Join(",", Episodes));
return string.Format("{0} - S{1:00}E{2}", CleanTitle, SeasonNumber,
String.Join("-", Episodes));
}
}

View file

@ -72,6 +72,7 @@ public virtual EpisodeFile ImportFile(Series series, string filePath)
if (!_repository.Exists<EpisodeFile>(e => e.Path == Parser.NormalizePath(filePath)))
{
var parseResult = Parser.ParseEpisodeInfo(filePath);
parseResult.CleanTitle = series.Title;//replaces the nasty path as title to help with logging
if (parseResult == null)
return null;
@ -90,7 +91,7 @@ public virtual EpisodeFile ImportFile(Series series, string filePath)
}
else
{
Logger.Warn("Unable to find '{0}' in the database. File:{1}", parseResult, filePath);
Logger.Warn("Unable to find [{0}] in the database.[{1}]", parseResult, filePath);
}
}
else
@ -106,7 +107,7 @@ public virtual EpisodeFile ImportFile(Series series, string filePath)
}
else
{
Logger.Warn("Unable to find '{0}' in the database. File:{1}", parseResult, filePath);
Logger.Warn("Unable to find [{0}] in the database.[{1}]", parseResult, filePath);
}
}
}