/** * Remove the specified resource from storage. * * @param int $id * @return \Illuminate\Http\Response */ public function destroy($id) { $counselor = Counselor::find($id); if (!$counselor) { return $this->respondNotFound('Counselor does not exist.'); } if ($counselor->delete()) { return $this->respond(['message' => 'The counselor has been deleted.']); } else { return $this->respondUnprocessableEntity('There was a problem deleting the counselor.'); } }