mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-07-16 05:43:54 +03:00
[PR #6530] [CLOSED] Deduplicate code #11008
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/jellyfin/jellyfin/pull/6530
Author: @ferferga
Created: 9/8/2021
Status: ❌ Closed
Base:
master← Head:dedupe📝 Commits (4)
c7362d6Create new Image entity and deleted Artwork y ArtworkKindf931382Remove duplication moving ImageType to Jellyfin.Data1c8a7d2Remove duplicated DisplayPreferencesDto in MediaBrowser.Model in favor of Jellyfin.Apicc9c978Reference all ImageType to Jellyfin.Data📊 Changes
86 files changed (+200 additions, -278 deletions)
View changed files
📝
Emby.Dlna/Didl/DidlBuilder.cs(+1 -0)📝
Emby.Drawing/ImageProcessor.cs(+1 -0)📝
Emby.Photos/PhotoProvider.cs(+1 -0)📝
Emby.Server.Implementations/Channels/ChannelImageProvider.cs(+1 -1)📝
Emby.Server.Implementations/Collections/CollectionImageProvider.cs(+1 -1)📝
Emby.Server.Implementations/Images/BaseDynamicImageProvider.cs(+1 -1)📝
Emby.Server.Implementations/Images/DynamicImageProvider.cs(+1 -0)📝
Emby.Server.Implementations/Images/FolderImageProvider.cs(+0 -1)📝
Emby.Server.Implementations/Images/GenreImageProvider.cs(+0 -1)📝
Emby.Server.Implementations/Images/PlaylistImageProvider.cs(+1 -1)📝
Emby.Server.Implementations/LiveTv/LiveTvDtoService.cs(+1 -1)📝
Jellyfin.Api/Controllers/ArtistsController.cs(+0 -1)📝
Jellyfin.Api/Controllers/DisplayPreferencesController.cs(+4 -4)📝
Jellyfin.Api/Controllers/ImageController.cs(+1 -1)📝
Jellyfin.Api/Controllers/InstantMixController.cs(+1 -1)📝
Jellyfin.Api/Controllers/LibraryController.cs(+1 -0)📝
Jellyfin.Api/Controllers/LiveTvController.cs(+0 -1)📝
Jellyfin.Api/Controllers/MusicGenresController.cs(+0 -1)📝
Jellyfin.Api/Controllers/PersonsController.cs(+1 -1)📝
Jellyfin.Api/Controllers/PlaylistsController.cs(+1 -1)...and 66 more files
📄 Description
Removed two duplicate enums, cherrypicked from #6049.
The
ArtKindin theJellyfin.Datanamespace had the exact same fields as theImageTypeenum inMediaBrowser.Model.Entities. As the new code will reside inJellyfin.Data, it made sense to leave it in that namespace and rename it fromArtKindtoImageType. ImageType also seemed more correct to me, as the images we manage are not always artworks.In
Jellyfin.Apiwe had aDisplayPreferencesDtothat was an exact copy from one inMediaBrowser.Model. As theJellyfin.Apiis the namespace for new code, it makes sense to keep that version instead of the one in MediaBrowser.I also added the new "Image" entity I created in #6049 in this PR, as it didn't make any sense to me to keep an "Artwork" entity with an enum called "ImageType".
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.