/** * Displays the form for editing the specified event. * * @param string $id * * @return mixed */ public function edit($id) { $event = $this->event->find($id); $apiObject = $this->event->findApiObject($event->api_id); if ($apiObject) { return view('events.edit', compact('event', 'apiObject')); } abort(404); }