Merge branch 'master' into userdb-efcore

# Conflicts:
#	Emby.Server.Implementations/EntryPoints/ServerEventNotifier.cs
#	Emby.Server.Implementations/Library/UserManager.cs
#	Emby.Server.Implementations/Sorting/IsFavoriteOrLikeComparer.cs
#	Emby.Server.Implementations/Sorting/IsPlayedComparer.cs
#	Emby.Server.Implementations/Sorting/IsUnplayedComparer.cs
#	Emby.Server.Implementations/TV/TVSeriesManager.cs
#	Jellyfin.Server.Implementations/Users/DefaultAuthenticationProvider.cs
This commit is contained in:
Patrick Barron
2020-06-04 16:39:50 -04:00
334 changed files with 2011 additions and 1689 deletions

View File

@@ -1,3 +1,5 @@
#pragma warning disable CS1591
using System;
using Jellyfin.Data.Entities;
using MediaBrowser.Controller.Entities;
@@ -27,6 +29,12 @@ namespace Emby.Server.Implementations.Sorting
/// <value>The user data repository.</value>
public IUserDataManager UserDataRepository { get; set; }
/// <summary>
/// Gets the name.
/// </summary>
/// <value>The name.</value>
public string Name => ItemSortBy.DateLastContentAdded;
/// <summary>
/// Compares the specified x.
/// </summary>
@@ -45,9 +53,7 @@ namespace Emby.Server.Implementations.Sorting
/// <returns>DateTime.</returns>
private static DateTime GetDate(BaseItem x)
{
var folder = x as Folder;
if (folder != null)
if (x is Folder folder)
{
if (folder.DateLastMediaAdded.HasValue)
{
@@ -57,11 +63,5 @@ namespace Emby.Server.Implementations.Sorting
return DateTime.MinValue;
}
/// <summary>
/// Gets the name.
/// </summary>
/// <value>The name.</value>
public string Name => ItemSortBy.DateLastContentAdded;
}
}