diff options
| author | Erwin de Haan <EraYaN@users.noreply.github.com> | 2019-01-13 21:31:14 +0100 |
|---|---|---|
| committer | Erwin de Haan <EraYaN@users.noreply.github.com> | 2019-01-13 21:31:14 +0100 |
| commit | a36658f6f0ed342d8b55dbf7c9ff95fe3abfa818 (patch) | |
| tree | b1484407efd83b243d0ea792b18c598e9ff53053 /Emby.Naming | |
| parent | 9fa60ec9340cbc8b4ed3e866fcf61852077902a1 (diff) | |
ReSharper Reformat: Properties to expression bodied form.
Diffstat (limited to 'Emby.Naming')
| -rw-r--r-- | Emby.Naming/Common/EpisodeExpression.cs | 11 | ||||
| -rw-r--r-- | Emby.Naming/Video/VideoFileInfo.cs | 5 |
2 files changed, 4 insertions, 12 deletions
diff --git a/Emby.Naming/Common/EpisodeExpression.cs b/Emby.Naming/Common/EpisodeExpression.cs index ebaacd3a1..fd85bf76a 100644 --- a/Emby.Naming/Common/EpisodeExpression.cs +++ b/Emby.Naming/Common/EpisodeExpression.cs @@ -6,7 +6,8 @@ namespace Emby.Naming.Common public class EpisodeExpression { private string _expression; - public string Expression { get { return _expression; } set { _expression = value; _regex = null; } } + public string Expression { get => _expression; + set { _expression = value; _regex = null; } } public bool IsByDate { get; set; } public bool IsOptimistic { get; set; } @@ -16,13 +17,7 @@ namespace Emby.Naming.Common public string[] DateTimeFormats { get; set; } private Regex _regex; - public Regex Regex - { - get - { - return _regex ?? (_regex = new Regex(Expression, RegexOptions.IgnoreCase | RegexOptions.Compiled)); - } - } + public Regex Regex => _regex ?? (_regex = new Regex(Expression, RegexOptions.IgnoreCase | RegexOptions.Compiled)); public EpisodeExpression(string expression, bool byDate) { diff --git a/Emby.Naming/Video/VideoFileInfo.cs b/Emby.Naming/Video/VideoFileInfo.cs index d14d04b20..6a29ada7e 100644 --- a/Emby.Naming/Video/VideoFileInfo.cs +++ b/Emby.Naming/Video/VideoFileInfo.cs @@ -65,10 +65,7 @@ namespace Emby.Naming.Video /// Gets the file name without extension. /// </summary> /// <value>The file name without extension.</value> - public string FileNameWithoutExtension - { - get { return !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() { |
