/** * Handle the event. * * @param UserWasCreated $event * @return void */ public function handle(UserWasCreated $event) { /** * Assign Default Settings */ $this->repository->createDefault($event->user->id); }
/** * Execute the command. * * @param SettingRepositoryInterface $repository */ public function handle(SettingRepositoryInterface $repository) { $status = $repository->update($this->setting_id, $this->fields); if (!$status) { dd('Settings couldnt be updated'); } }