diff --git a/Emby.Naming/AudioBook/AudioBookFileInfo.cs b/Emby.Naming/AudioBook/AudioBookFileInfo.cs
index 0bc6ec7e40..b54f8b33a2 100644
--- a/Emby.Naming/AudioBook/AudioBookFileInfo.cs
+++ b/Emby.Naming/AudioBook/AudioBookFileInfo.cs
@@ -3,41 +3,41 @@ using System;
namespace Emby.Naming.AudioBook
{
///
- /// Represents a single video file.
+ /// Represents a single video file.
///
public class AudioBookFileInfo : IComparable
{
///
- /// Gets or sets the path.
+ /// Gets or sets the path.
///
/// The path.
public string Path { get; set; }
///
- /// Gets or sets the container.
+ /// Gets or sets the container.
///
/// The container.
public string Container { get; set; }
///
- /// Gets or sets the part number.
+ /// Gets or sets the part number.
///
/// The part number.
public int? PartNumber { get; set; }
///
- /// Gets or sets the chapter number.
+ /// Gets or sets the chapter number.
///
/// The chapter number.
public int? ChapterNumber { get; set; }
///
- /// Gets or sets a value indicating whether this instance is a directory.
+ /// Gets or sets a value indicating whether this instance is a directory.
///
/// The type.
public bool IsDirectory { get; set; }
- ///
+ ///
public int CompareTo(AudioBookFileInfo other)
{
if (ReferenceEquals(this, other))
diff --git a/Emby.Naming/AudioBook/AudioBookInfo.cs b/Emby.Naming/AudioBook/AudioBookInfo.cs
index b0b5bd881f..c97b784385 100644
--- a/Emby.Naming/AudioBook/AudioBookInfo.cs
+++ b/Emby.Naming/AudioBook/AudioBookInfo.cs
@@ -3,12 +3,12 @@ using System.Collections.Generic;
namespace Emby.Naming.AudioBook
{
///
- /// Represents a complete video, including all parts and subtitles.
+ /// Represents a complete video, including all parts and subtitles.
///
public class AudioBookInfo
{
///
- /// Initializes a new instance of the class.
+ /// Initializes a new instance of the class.
///
public AudioBookInfo()
{
@@ -18,30 +18,30 @@ namespace Emby.Naming.AudioBook
}
///
- /// Gets or sets the name.
+ /// Gets or sets the name.
///
/// The name.
public string Name { get; set; }
///
- /// Gets or sets the year.
+ /// Gets or sets the year.
///
public int? Year { get; set; }
///
- /// Gets or sets the files.
+ /// Gets or sets the files.
///
/// The files.
public List Files { get; set; }
///
- /// Gets or sets the extras.
+ /// Gets or sets the extras.
///
/// The extras.
public List Extras { get; set; }
///
- /// Gets or sets the alternate versions.
+ /// Gets or sets the alternate versions.
///
/// The alternate versions.
public List AlternateVersions { get; set; }
diff --git a/Emby.Naming/AudioBook/AudioBookListResolver.cs b/Emby.Naming/AudioBook/AudioBookListResolver.cs
index 081510f952..f4ba11a0d1 100644
--- a/Emby.Naming/AudioBook/AudioBookListResolver.cs
+++ b/Emby.Naming/AudioBook/AudioBookListResolver.cs
@@ -29,11 +29,7 @@ namespace Emby.Naming.AudioBook
// Filter out all extras, otherwise they could cause stacks to not be resolved
// See the unit test TestStackedWithTrailer
var metadata = audiobookFileInfos
- .Select(i => new FileSystemMetadata
- {
- FullName = i.Path,
- IsDirectory = i.IsDirectory
- });
+ .Select(i => new FileSystemMetadata { FullName = i.Path, IsDirectory = i.IsDirectory });
var stackResult = new StackResolver(_options)
.ResolveAudioBooks(metadata);
@@ -42,11 +38,7 @@ namespace Emby.Naming.AudioBook
{
var stackFiles = stack.Files.Select(i => audioBookResolver.Resolve(i, stack.IsDirectoryStack)).ToList();
stackFiles.Sort();
- var info = new AudioBookInfo
- {
- Files = stackFiles,
- Name = stack.Name
- };
+ var info = new AudioBookInfo { Files = stackFiles, Name = stack.Name };
yield return info;
}
diff --git a/Emby.Naming/Common/MediaType.cs b/Emby.Naming/Common/MediaType.cs
index cc18ce4cdd..bfedc50b60 100644
--- a/Emby.Naming/Common/MediaType.cs
+++ b/Emby.Naming/Common/MediaType.cs
@@ -5,17 +5,17 @@ namespace Emby.Naming.Common
public enum MediaType
{
///
- /// The audio
+ /// The audio
///
Audio = 0,
///
- /// The photo
+ /// The photo
///
Photo = 1,
///
- /// The video
+ /// The video
///
Video = 2
}
diff --git a/Emby.Naming/Subtitles/SubtitleInfo.cs b/Emby.Naming/Subtitles/SubtitleInfo.cs
index f39c496b7a..0aee439c1a 100644
--- a/Emby.Naming/Subtitles/SubtitleInfo.cs
+++ b/Emby.Naming/Subtitles/SubtitleInfo.cs
@@ -5,25 +5,25 @@ namespace Emby.Naming.Subtitles
public class SubtitleInfo
{
///
- /// Gets or sets the path.
+ /// Gets or sets the path.
///
/// The path.
public string Path { get; set; }
///
- /// Gets or sets the language.
+ /// Gets or sets the language.
///
/// The language.
public string Language { get; set; }
///
- /// Gets or sets a value indicating whether this instance is default.
+ /// Gets or sets a value indicating whether this instance is default.
///
/// true if this instance is default; otherwise, false.
public bool IsDefault { get; set; }
///
- /// Gets or sets a value indicating whether this instance is forced.
+ /// Gets or sets a value indicating whether this instance is forced.
///
/// true if this instance is forced; otherwise, false.
public bool IsForced { get; set; }
diff --git a/Emby.Naming/Subtitles/SubtitleParser.cs b/Emby.Naming/Subtitles/SubtitleParser.cs
index 082696da4f..5797c6bfa6 100644
--- a/Emby.Naming/Subtitles/SubtitleParser.cs
+++ b/Emby.Naming/Subtitles/SubtitleParser.cs
@@ -37,7 +37,9 @@ namespace Emby.Naming.Subtitles
IsForced = _options.SubtitleForcedFlags.Any(i => flags.Contains(i, StringComparer.OrdinalIgnoreCase))
};
- var parts = flags.Where(i => !_options.SubtitleDefaultFlags.Contains(i, StringComparer.OrdinalIgnoreCase) && !_options.SubtitleForcedFlags.Contains(i, StringComparer.OrdinalIgnoreCase))
+ var parts = flags.Where(i =>
+ !_options.SubtitleDefaultFlags.Contains(i, StringComparer.OrdinalIgnoreCase) &&
+ !_options.SubtitleForcedFlags.Contains(i, StringComparer.OrdinalIgnoreCase))
.ToList();
// Should have a name, language and file extension
diff --git a/Emby.Naming/TV/EpisodeInfo.cs b/Emby.Naming/TV/EpisodeInfo.cs
index 250df4e2d3..209f01c007 100644
--- a/Emby.Naming/TV/EpisodeInfo.cs
+++ b/Emby.Naming/TV/EpisodeInfo.cs
@@ -5,43 +5,43 @@ namespace Emby.Naming.TV
public class EpisodeInfo
{
///
- /// Gets or sets the path.
+ /// Gets or sets the path.
///
/// The path.
public string Path { get; set; }
///
- /// Gets or sets the container.
+ /// Gets or sets the container.
///
/// The container.
public string Container { get; set; }
///
- /// Gets or sets the name of the series.
+ /// Gets or sets the name of the series.
///
/// The name of the series.
public string SeriesName { get; set; }
///
- /// Gets or sets the format3 d.
+ /// Gets or sets the format3 d.
///
/// The format3 d.
public string Format3D { get; set; }
///
- /// Gets or sets a value indicating whether [is3 d].
+ /// Gets or sets a value indicating whether [is3 d].
///
/// true if [is3 d]; otherwise, false.
public bool Is3D { get; set; }
///
- /// Gets or sets a value indicating whether this instance is stub.
+ /// Gets or sets a value indicating whether this instance is stub.
///
/// true if this instance is stub; otherwise, false.
public bool IsStub { get; set; }
///
- /// Gets or sets the type of the stub.
+ /// Gets or sets the type of the stub.
///
/// The type of the stub.
public string StubType { get; set; }
diff --git a/Emby.Naming/TV/EpisodePathParser.cs b/Emby.Naming/TV/EpisodePathParser.cs
index d3a822b173..a6af689c72 100644
--- a/Emby.Naming/TV/EpisodePathParser.cs
+++ b/Emby.Naming/TV/EpisodePathParser.cs
@@ -18,7 +18,13 @@ namespace Emby.Naming.TV
_options = options;
}
- public EpisodePathParserResult Parse(string path, bool isDirectory, bool? isNamed = null, bool? isOptimistic = null, bool? supportsAbsoluteNumbers = null, bool fillExtendedInfo = true)
+ public EpisodePathParserResult Parse(
+ string path,
+ bool isDirectory,
+ bool? isNamed = null,
+ bool? isOptimistic = null,
+ bool? supportsAbsoluteNumbers = null,
+ bool fillExtendedInfo = true)
{
// Added to be able to use regex patterns which require a file extension.
// There were no failed tests without this block, but to be safe, we can keep it until
@@ -64,7 +70,7 @@ namespace Emby.Naming.TV
{
result.SeriesName = result.SeriesName
.Trim()
- .Trim(new[] { '_', '.', '-' })
+ .Trim('_', '.', '-')
.Trim();
}
}
diff --git a/Emby.Naming/TV/SeasonPathParser.cs b/Emby.Naming/TV/SeasonPathParser.cs
index 2fa6b43531..d6c66fcc52 100644
--- a/Emby.Naming/TV/SeasonPathParser.cs
+++ b/Emby.Naming/TV/SeasonPathParser.cs
@@ -9,7 +9,7 @@ namespace Emby.Naming.TV
public static class SeasonPathParser
{
///
- /// A season folder must contain one of these somewhere in the name.
+ /// A season folder must contain one of these somewhere in the name.
///
private static readonly string[] _seasonFolderNames =
{
@@ -41,7 +41,7 @@ namespace Emby.Naming.TV
}
///
- /// Gets the season number from path.
+ /// Gets the season number from path.
///
/// The path.
/// if set to true [support special aliases].
diff --git a/Emby.Naming/TV/SeasonPathParserResult.cs b/Emby.Naming/TV/SeasonPathParserResult.cs
index 44090c059f..702ca6ac52 100644
--- a/Emby.Naming/TV/SeasonPathParserResult.cs
+++ b/Emby.Naming/TV/SeasonPathParserResult.cs
@@ -5,13 +5,13 @@ namespace Emby.Naming.TV
public class SeasonPathParserResult
{
///
- /// Gets or sets the season number.
+ /// Gets or sets the season number.
///
/// The season number.
public int? SeasonNumber { get; set; }
///
- /// Gets or sets a value indicating whether this is success.
+ /// Gets or sets a value indicating whether this is success.
///
/// true if success; otherwise, false.
public bool Success { get; set; }
diff --git a/Emby.Naming/Video/CleanDateTimeParser.cs b/Emby.Naming/Video/CleanDateTimeParser.cs
index 579c9e91e1..78efeeabc3 100644
--- a/Emby.Naming/Video/CleanDateTimeParser.cs
+++ b/Emby.Naming/Video/CleanDateTimeParser.cs
@@ -8,7 +8,7 @@ using System.Text.RegularExpressions;
namespace Emby.Naming.Video
{
///
- /// .
+ /// .
///
public static class CleanDateTimeParser
{
diff --git a/Emby.Naming/Video/CleanDateTimeResult.cs b/Emby.Naming/Video/CleanDateTimeResult.cs
index 57eeaa7e32..22d0fe4e92 100644
--- a/Emby.Naming/Video/CleanDateTimeResult.cs
+++ b/Emby.Naming/Video/CleanDateTimeResult.cs
@@ -18,13 +18,13 @@ namespace Emby.Naming.Video
}
///
- /// Gets the name.
+ /// Gets the name.
///
/// The name.
public string Name { get; }
///
- /// Gets the year.
+ /// Gets the year.
///
/// The year.
public int? Year { get; }
diff --git a/Emby.Naming/Video/CleanStringParser.cs b/Emby.Naming/Video/CleanStringParser.cs
index 3f584d5847..225efc3ac2 100644
--- a/Emby.Naming/Video/CleanStringParser.cs
+++ b/Emby.Naming/Video/CleanStringParser.cs
@@ -8,7 +8,7 @@ using System.Text.RegularExpressions;
namespace Emby.Naming.Video
{
///
- /// .
+ /// .
///
public static class CleanStringParser
{
diff --git a/Emby.Naming/Video/ExtraResult.cs b/Emby.Naming/Video/ExtraResult.cs
index 15db32e876..0d7c0bab2b 100644
--- a/Emby.Naming/Video/ExtraResult.cs
+++ b/Emby.Naming/Video/ExtraResult.cs
@@ -7,13 +7,13 @@ namespace Emby.Naming.Video
public class ExtraResult
{
///
- /// Gets or sets the type of the extra.
+ /// Gets or sets the type of the extra.
///
/// The type of the extra.
public ExtraType? ExtraType { get; set; }
///
- /// Gets or sets the rule.
+ /// Gets or sets the rule.
///
/// The rule.
public ExtraRule Rule { get; set; }
diff --git a/Emby.Naming/Video/ExtraRule.cs b/Emby.Naming/Video/ExtraRule.cs
index cb58a39347..4f9504a659 100644
--- a/Emby.Naming/Video/ExtraRule.cs
+++ b/Emby.Naming/Video/ExtraRule.cs
@@ -8,25 +8,25 @@ namespace Emby.Naming.Video
public class ExtraRule
{
///
- /// Gets or sets the token.
+ /// Gets or sets the token.
///
/// The token.
public string Token { get; set; }
///
- /// Gets or sets the type of the extra.
+ /// Gets or sets the type of the extra.
///
/// The type of the extra.
public ExtraType ExtraType { get; set; }
///
- /// Gets or sets the type of the rule.
+ /// Gets or sets the type of the rule.
///
/// The type of the rule.
public ExtraRuleType RuleType { get; set; }
///
- /// Gets or sets the type of the media.
+ /// Gets or sets the type of the media.
///
/// The type of the media.
public MediaType MediaType { get; set; }
diff --git a/Emby.Naming/Video/ExtraRuleType.cs b/Emby.Naming/Video/ExtraRuleType.cs
index b021a04a31..10afd002f3 100644
--- a/Emby.Naming/Video/ExtraRuleType.cs
+++ b/Emby.Naming/Video/ExtraRuleType.cs
@@ -5,17 +5,17 @@ namespace Emby.Naming.Video
public enum ExtraRuleType
{
///
- /// The suffix
+ /// The suffix
///
Suffix = 0,
///
- /// The filename
+ /// The filename
///
Filename = 1,
///
- /// The regex
+ /// The regex
///
Regex = 2
}
diff --git a/Emby.Naming/Video/Format3DResult.cs b/Emby.Naming/Video/Format3DResult.cs
index fa0e9d3b80..6a9ade8228 100644
--- a/Emby.Naming/Video/Format3DResult.cs
+++ b/Emby.Naming/Video/Format3DResult.cs
@@ -12,19 +12,19 @@ namespace Emby.Naming.Video
}
///
- /// Gets or sets a value indicating whether [is3 d].
+ /// Gets or sets a value indicating whether [is3 d].
///
/// true if [is3 d]; otherwise, false.
public bool Is3D { get; set; }
///
- /// Gets or sets the format3 d.
+ /// Gets or sets the format3 d.
///
/// The format3 d.
public string Format3D { get; set; }
///
- /// Gets or sets the tokens.
+ /// Gets or sets the tokens.
///
/// The tokens.
public List Tokens { get; set; }
diff --git a/Emby.Naming/Video/Format3DRule.cs b/Emby.Naming/Video/Format3DRule.cs
index 310ec84e8f..633f40d282 100644
--- a/Emby.Naming/Video/Format3DRule.cs
+++ b/Emby.Naming/Video/Format3DRule.cs
@@ -5,13 +5,13 @@ namespace Emby.Naming.Video
public class Format3DRule
{
///
- /// Gets or sets the token.
+ /// Gets or sets the token.
///
/// The token.
public string Token { get; set; }
///
- /// Gets or sets the preceeding token.
+ /// Gets or sets the preceeding token.
///
/// The preceeding token.
public string PreceedingToken { get; set; }
diff --git a/Emby.Naming/Video/StackResolver.cs b/Emby.Naming/Video/StackResolver.cs
index ee05904c75..a943839f2b 100644
--- a/Emby.Naming/Video/StackResolver.cs
+++ b/Emby.Naming/Video/StackResolver.cs
@@ -21,31 +21,20 @@ namespace Emby.Naming.Video
public IEnumerable ResolveDirectories(IEnumerable files)
{
- return Resolve(files.Select(i => new FileSystemMetadata
- {
- FullName = i,
- IsDirectory = true
- }));
+ return Resolve(files.Select(i => new FileSystemMetadata { FullName = i, IsDirectory = true }));
}
public IEnumerable ResolveFiles(IEnumerable files)
{
- return Resolve(files.Select(i => new FileSystemMetadata
- {
- FullName = i,
- IsDirectory = false
- }));
+ return Resolve(files.Select(i => new FileSystemMetadata { FullName = i, IsDirectory = false }));
}
public IEnumerable ResolveAudioBooks(IEnumerable files)
{
- foreach (var directory in files.GroupBy(file => file.IsDirectory ? file.FullName : Path.GetDirectoryName(file.FullName)))
+ foreach (var directory in files.GroupBy(file =>
+ file.IsDirectory ? file.FullName : Path.GetDirectoryName(file.FullName)))
{
- var stack = new FileStack()
- {
- Name = Path.GetFileName(directory.Key),
- IsDirectoryStack = false
- };
+ var stack = new FileStack { Name = Path.GetFileName(directory.Key), IsDirectoryStack = false };
foreach (var file in directory)
{
if (file.IsDirectory)
diff --git a/Emby.Naming/Video/StubResult.cs b/Emby.Naming/Video/StubResult.cs
index 1b8e99b0dc..fdde6fc279 100644
--- a/Emby.Naming/Video/StubResult.cs
+++ b/Emby.Naming/Video/StubResult.cs
@@ -5,13 +5,13 @@ namespace Emby.Naming.Video
public struct StubResult
{
///
- /// Gets or sets a value indicating whether this instance is stub.
+ /// Gets or sets a value indicating whether this instance is stub.
///
/// true if this instance is stub; otherwise, false.
public bool IsStub { get; set; }
///
- /// Gets or sets the type of the stub.
+ /// Gets or sets the type of the stub.
///
/// The type of the stub.
public string StubType { get; set; }
diff --git a/Emby.Naming/Video/StubTypeRule.cs b/Emby.Naming/Video/StubTypeRule.cs
index 8285cb51a3..88ee586834 100644
--- a/Emby.Naming/Video/StubTypeRule.cs
+++ b/Emby.Naming/Video/StubTypeRule.cs
@@ -5,13 +5,13 @@ namespace Emby.Naming.Video
public class StubTypeRule
{
///
- /// Gets or sets the token.
+ /// Gets or sets the token.
///
/// The token.
public string Token { get; set; }
///
- /// Gets or sets the type of the stub.
+ /// Gets or sets the type of the stub.
///
/// The type of the stub.
public string StubType { get; set; }
diff --git a/Emby.Naming/Video/VideoFileInfo.cs b/Emby.Naming/Video/VideoFileInfo.cs
index aa4f3a35c3..475843c96c 100644
--- a/Emby.Naming/Video/VideoFileInfo.cs
+++ b/Emby.Naming/Video/VideoFileInfo.cs
@@ -3,81 +3,83 @@ using MediaBrowser.Model.Entities;
namespace Emby.Naming.Video
{
///
- /// Represents a single video file.
+ /// Represents a single video file.
///
public class VideoFileInfo
{
///
- /// Gets or sets the path.
+ /// Gets or sets the path.
///
/// The path.
public string Path { get; set; }
///
- /// Gets or sets the container.
+ /// Gets or sets the container.
///
/// The container.
public string Container { get; set; }
///
- /// Gets or sets the name.
+ /// Gets or sets the name.
///
/// The name.
public string Name { get; set; }
///
- /// Gets or sets the year.
+ /// Gets or sets the year.
///
/// The year.
public int? Year { get; set; }
///
- /// Gets or sets the type of the extra, e.g. trailer, theme song, behind the scenes, etc.
+ /// Gets or sets the type of the extra, e.g. trailer, theme song, behind the scenes, etc.
///
/// The type of the extra.
public ExtraType? ExtraType { get; set; }
///
- /// Gets or sets the extra rule.
+ /// Gets or sets the extra rule.
///
/// The extra rule.
public ExtraRule ExtraRule { get; set; }
///
- /// Gets or sets the format3 d.
+ /// Gets or sets the format3 d.
///
/// The format3 d.
public string Format3D { get; set; }
///
- /// Gets or sets a value indicating whether [is3 d].
+ /// Gets or sets a value indicating whether [is3 d].
///
/// true if [is3 d]; otherwise, false.
public bool Is3D { get; set; }
///
- /// Gets or sets a value indicating whether this instance is stub.
+ /// Gets or sets a value indicating whether this instance is stub.
///
/// true if this instance is stub; otherwise, false.
public bool IsStub { get; set; }
///
- /// Gets or sets the type of the stub.
+ /// Gets or sets the type of the stub.
///
/// The type of the stub.
public string StubType { get; set; }
///
- /// Gets or sets a value indicating whether this instance is a directory.
+ /// Gets or sets a value indicating whether this instance is a directory.
///
/// The type.
public bool IsDirectory { get; set; }
///
- /// Gets the file name without extension.
+ /// Gets the file name without extension.
///
/// The file name without extension.
- public string FileNameWithoutExtension => !IsDirectory ? System.IO.Path.GetFileNameWithoutExtension(Path) : System.IO.Path.GetFileName(Path);
+ public string FileNameWithoutExtension => !IsDirectory
+ ? System.IO.Path.GetFileNameWithoutExtension(Path)
+ : System.IO.Path.GetFileName(Path);
///
public override string ToString()
diff --git a/Emby.Naming/Video/VideoInfo.cs b/Emby.Naming/Video/VideoInfo.cs
index ea74c40e2a..3b2137fb76 100644
--- a/Emby.Naming/Video/VideoInfo.cs
+++ b/Emby.Naming/Video/VideoInfo.cs
@@ -4,12 +4,12 @@ using System.Collections.Generic;
namespace Emby.Naming.Video
{
///
- /// Represents a complete video, including all parts and subtitles.
+ /// Represents a complete video, including all parts and subtitles.
///
public class VideoInfo
{
///
- /// Initializes a new instance of the class.
+ /// Initializes a new instance of the class.
///
/// The name.
public VideoInfo(string name)
@@ -22,31 +22,31 @@ namespace Emby.Naming.Video
}
///
- /// Gets or sets the name.
+ /// Gets or sets the name.
///
/// The name.
public string Name { get; set; }
///
- /// Gets or sets the year.
+ /// Gets or sets the year.
///
/// The year.
public int? Year { get; set; }
///
- /// Gets or sets the files.
+ /// Gets or sets the files.
///
/// The files.
public IReadOnlyList Files { get; set; }
///
- /// Gets or sets the extras.
+ /// Gets or sets the extras.
///
/// The extras.
public IReadOnlyList Extras { get; set; }
///
- /// Gets or sets the alternate versions.
+ /// Gets or sets the alternate versions.
///
/// The alternate versions.
public IReadOnlyList AlternateVersions { get; set; }
diff --git a/Emby.Naming/Video/VideoListResolver.cs b/Emby.Naming/Video/VideoListResolver.cs
index d4b02cf2a6..29b42cdc1d 100644
--- a/Emby.Naming/Video/VideoListResolver.cs
+++ b/Emby.Naming/Video/VideoListResolver.cs
@@ -33,11 +33,7 @@ namespace Emby.Naming.Video
// See the unit test TestStackedWithTrailer
var nonExtras = videoInfos
.Where(i => i.ExtraType == null)
- .Select(i => new FileSystemMetadata
- {
- FullName = i.Path,
- IsDirectory = i.IsDirectory
- });
+ .Select(i => new FileSystemMetadata { FullName = i.Path, IsDirectory = i.IsDirectory });
var stackResult = new StackResolver(_options)
.Resolve(nonExtras).ToList();
@@ -57,11 +53,7 @@ namespace Emby.Naming.Video
info.Year = info.Files[0].Year;
- var extraBaseNames = new List
- {
- stack.Name,
- Path.GetFileNameWithoutExtension(stack.Files[0])
- };
+ var extraBaseNames = new List { stack.Name, Path.GetFileNameWithoutExtension(stack.Files[0]) };
var extras = GetExtras(remainingFiles, extraBaseNames);
@@ -83,10 +75,7 @@ namespace Emby.Naming.Video
foreach (var media in standaloneMedia)
{
- var info = new VideoInfo(media.Name)
- {
- Files = new List { media }
- };
+ var info = new VideoInfo(media.Name) { Files = new List { media } };
info.Year = info.Files[0].Year;
@@ -162,8 +151,7 @@ namespace Emby.Naming.Video
// Whatever files are left, just add them
list.AddRange(remainingFiles.Select(i => new VideoInfo(i.Name)
{
- Files = new List { i },
- Year = i.Year
+ Files = new List { i }, Year = i.Year
}));
return list;
@@ -183,7 +171,7 @@ namespace Emby.Naming.Video
if (!string.IsNullOrEmpty(folderName)
&& folderName.Length > 1
&& videos.All(i => i.Files.Count == 1
- && IsEligibleForMultiVersion(folderName, i.Files[0].Path))
+ && IsEligibleForMultiVersion(folderName, i.Files[0].Path))
&& HaveSameYear(videos))
{
var ordered = videos.OrderBy(i => i.Name).ToList();
@@ -222,8 +210,8 @@ namespace Emby.Naming.Video
{
testFilename = testFilename.Substring(folderName.Length).Trim();
return string.IsNullOrEmpty(testFilename)
- || testFilename[0] == '-'
- || string.IsNullOrWhiteSpace(Regex.Replace(testFilename, @"\[([^]]*)\]", string.Empty));
+ || testFilename[0] == '-'
+ || string.IsNullOrWhiteSpace(Regex.Replace(testFilename, @"\[([^]]*)\]", string.Empty));
}
return false;
@@ -239,7 +227,8 @@ namespace Emby.Naming.Video
return remainingFiles
.Where(i => i.ExtraType == null)
- .Where(i => baseNames.Any(b => i.FileNameWithoutExtension.StartsWith(b, StringComparison.OrdinalIgnoreCase)))
+ .Where(i => baseNames.Any(b =>
+ i.FileNameWithoutExtension.StartsWith(b, StringComparison.OrdinalIgnoreCase)))
.ToList();
}
}
diff --git a/Emby.Naming/Video/VideoResolver.cs b/Emby.Naming/Video/VideoResolver.cs
index 0b75a8cce9..7dbd2ec7f4 100644
--- a/Emby.Naming/Video/VideoResolver.cs
+++ b/Emby.Naming/Video/VideoResolver.cs
@@ -18,7 +18,7 @@ namespace Emby.Naming.Video
}
///
- /// Resolves the directory.
+ /// Resolves the directory.
///
/// The path.
/// VideoFileInfo.
@@ -28,7 +28,7 @@ namespace Emby.Naming.Video
}
///
- /// Resolves the file.
+ /// Resolves the file.
///
/// The path.
/// VideoFileInfo.
@@ -38,7 +38,7 @@ namespace Emby.Naming.Video
}
///
- /// Resolves the specified path.
+ /// Resolves the specified path.
///
/// The path.
/// if set to true [is folder].
diff --git a/MediaBrowser.Model/Entities/ChapterInfo.cs b/MediaBrowser.Model/Entities/ChapterInfo.cs
index 2903ef61b4..bea7ec1dba 100644
--- a/MediaBrowser.Model/Entities/ChapterInfo.cs
+++ b/MediaBrowser.Model/Entities/ChapterInfo.cs
@@ -26,6 +26,7 @@ namespace MediaBrowser.Model.Entities
///
/// The image path.
public string ImagePath { get; set; }
+
public DateTime ImageDateModified { get; set; }
public string ImageTag { get; set; }