mirror of
https://github.com/koel/koel.git
synced 2026-04-25 16:56:02 +03:00
[PR #2141] [MERGED] refactor: simplify all those image urls and paths #2103
Labels
No labels
Authentication
Dependencies
Documentation
Feature Request
Flac
Help Wanted
Installation/Setup
Integration
Mobile
PR Welcome
Pending Release
Performance
Playlist
S3
Search
Sync
[Pri] Low
[Pri] Normal
[Status] Keep Open
[Status] Needs Author Reply
[Status] Needs Review
[Status] Stale
[Status] Will Implement
[Type] Blessed
[Type] Bug
[Type] Duplicate
[Type] Enhancement
[Type] Help Request
[Type] Question
[Type] Task
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/koel-koel#2103
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
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/koel/koel/pull/2141
Author: @phanan
Created: 10/21/2025
Status: ✅ Merged
Merged: 10/21/2025
Merged by: @phanan
Base:
master← Head:path-url📝 Commits (1)
1bb173arefactor: simplify all those image urls and paths📊 Changes
38 files changed (+115 additions, -212 deletions)
View changed files
📝
app/Helpers.php(+4 -4)📝
app/Http/Controllers/API/AlbumCoverController.php(+1 -1)📝
app/Http/Controllers/API/Artist/ArtistImageController.php(+1 -1)📝
app/Http/Controllers/API/FetchAlbumThumbnailController.php(+3 -1)📝
app/Http/Controllers/API/PlaylistCoverController.php(+1 -1)📝
app/Http/Resources/AlbumResource.php(+1 -1)📝
app/Http/Resources/ArtistResource.php(+1 -1)📝
app/Http/Resources/PlaylistResource.php(+1 -1)📝
app/Http/Resources/RadioStationResource.php(+1 -1)📝
app/Http/Resources/SongResource.php(+1 -1)📝
app/Models/Album.php(+8 -46)📝
app/Models/Artist.php(+2 -28)📝
app/Models/Playlist.php(+1 -17)📝
app/Models/RadioStation.php(+1 -18)📝
app/Observers/AlbumObserver.php(+4 -4)📝
app/Observers/ArtistObserver.php(+1 -1)📝
app/Observers/PlaylistObserver.php(+1 -1)📝
app/Observers/RadioStationObserver.php(+1 -9)📝
app/Services/EncyclopediaService.php(+2 -2)📝
app/Services/ImageStorage.php(+36 -32)...and 18 more files
📄 Description
Description
Remove the "smart" URl and path attributes for image fields on artist, album, playlist, etc. Instead, use explicit functions (
image_storage_url()andimage_storage_path()) to turn the field values (file names) into URLs and paths only when necessary, e.g. in HTTP resources.Motivation
Screenshots (if applicable)
Checklist
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.