mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-22 01:54:42 +01:00
sync updates
This commit is contained in:
@@ -402,15 +402,17 @@ namespace MediaBrowser.Server.Implementations.Library
|
||||
return dto;
|
||||
}
|
||||
|
||||
public UserDto GetOfflineUserDto(User user, string deviceId)
|
||||
public UserDto GetOfflineUserDto(User user)
|
||||
{
|
||||
var dto = GetUserDto(user);
|
||||
|
||||
var offlinePasswordHash = GetLocalPasswordHash(user);
|
||||
dto.HasPassword = !IsPasswordEmpty(offlinePasswordHash);
|
||||
|
||||
dto.OfflinePasswordSalt = Guid.NewGuid().ToString("N");
|
||||
|
||||
// Hash the pin with the device Id to create a unique result for this device
|
||||
dto.OfflinePassword = GetSha1String((offlinePasswordHash + deviceId).ToLower());
|
||||
dto.OfflinePassword = GetSha1String((offlinePasswordHash + dto.OfflinePasswordSalt).ToLower());
|
||||
|
||||
dto.ServerName = _appHost.FriendlyName;
|
||||
|
||||
|
||||
@@ -86,7 +86,8 @@ namespace MediaBrowser.Server.Implementations.Library
|
||||
list.Add(await GetUserView(CollectionType.Movies, string.Empty, cancellationToken).ConfigureAwait(false));
|
||||
}
|
||||
|
||||
if (foldersWithViewTypes.Any(i => string.Equals(i.CollectionType, CollectionType.Games, StringComparison.OrdinalIgnoreCase)))
|
||||
if (foldersWithViewTypes.Any(i => string.Equals(i.CollectionType, CollectionType.Games, StringComparison.OrdinalIgnoreCase))
|
||||
|| _config.Configuration.EnableLegacyCollections)
|
||||
{
|
||||
list.Add(await GetUserView(CollectionType.Games, string.Empty, cancellationToken).ConfigureAwait(false));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user