mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-17 23:56:44 +00:00
Add migration to properly set playlist owner
This commit is contained in:
@@ -563,5 +563,19 @@ namespace Emby.Server.Implementations.Playlists
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public async Task UpdatePlaylist(Playlist playlist)
|
||||
{
|
||||
var currentPlaylist = (Playlist)_libraryManager.GetItemById(playlist.Id);
|
||||
currentPlaylist.OwnerUserId = playlist.OwnerUserId;
|
||||
currentPlaylist.Shares = playlist.Shares;
|
||||
|
||||
await playlist.UpdateToRepositoryAsync(ItemUpdateType.MetadataEdit, CancellationToken.None).ConfigureAwait(false);
|
||||
|
||||
if (playlist.IsFile)
|
||||
{
|
||||
SavePlaylistFile(currentPlaylist);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user