/** * Update an existing annotation. * * @param string $id */ public function putIndex($id = null) { //If no id requested, return 404 if ($id === null) { App::abort(404, 'No annotation id passed.'); } $body = Input::all(); $annotation = Annotation::createFromAnnotatorArray($body); $annotation->updateSearchIndex(); return Response::json($annotation); }