mirror of
https://github.com/koel/koel
synced 2025-02-17 22:08:28 +00:00
Fix playlist creation bug
This commit is contained in:
parent
b8d68bd74f
commit
339d0c464d
1 changed files with 1 additions and 1 deletions
|
@ -28,7 +28,7 @@ class PlaylistController extends Controller
|
|||
public function store(PlaylistStoreRequest $request)
|
||||
{
|
||||
$playlist = auth()->user()->playlists()->create($request->only('name'));
|
||||
$playlist->songs()->sync($request->input('songs'));
|
||||
$playlist->songs()->sync($request->input('songs', []));
|
||||
|
||||
$playlist->songs = $playlist->songs->pluck('id');
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue