public function postIndex($doc) { $comment = Input::get('comment'); $newComment = new Comment(); $newComment->user_id = Auth::user()->id; $newComment->doc_id = $comment['doc']['id']; $newComment->text = $comment['text']; $newComment->save(); // Late load the user. $newComment->user; return Response::json($newComment->toArray()); }