/** * Execute the command. * * @param UserRepositoryInterface $repository * @param Dispatcher $event */ public function handle(UserRepositoryInterface $repository, Dispatcher $event) { $status = $repository->update($this->user->getAttribute('id'), $this->fields); if (!$status) { dd('user wasnt updated somehow'); } $event->fire(new UserWasUpdated($this->user)); }