fix(api): restore br for lyrics in legacy API

This commit is contained in:
Phan An 2022-07-28 10:48:52 +02:00
parent 4a4bbaf8a7
commit 0e5e1c6089
No known key found for this signature in database
GPG key ID: A81E4477F0BB6FDC

View file

@ -18,7 +18,7 @@ class SongController extends Controller
public function show(Song $song)
{
return response()->json([
'lyrics' => $song->lyrics,
'lyrics' => nl2br($song->lyrics), // backward compat
'album_info' => $this->mediaInformationService->getAlbumInformation($song->album)?->toArray() ?: [],
'artist_info' => $this->mediaInformationService->getArtistInformation($song->artist)?->toArray() ?: [],
'youtube' => $this->youTubeService->searchVideosRelatedToSong($song),