/** * Show the form for editing the specified resource. * * @param int $id * @return Response */ public function edit($id) { if (Auth::check()) { $artists = \App\Artist::lists('name', 'id'); $song = \App\Song::find($id); return view('canciones.edit', compact('song', 'artists')); } else { return redirect(url()); } }
/** * Show the form for editing the specified resource. * * @param int $id * @return Response */ public function edit($id) { $artists = \App\Artist::lists('name', 'id'); $song = \App\Song::find($id); return view('canciones.edit', compact('song', 'artists')); }