Skip to content
This repository has been archived by the owner on Jan 10, 2020. It is now read-only.

We were unable to generate your profile, please try again later(Exception). #199

Open
eldersoon opened this issue Aug 30, 2019 · 0 comments

Comments

@eldersoon
Copy link

eldersoon commented Aug 30, 2019

When I try to register a new user, I get this exception. I can't find what is wrong.

C:\path\to\my\cms\app\Services\UserService.php

public function create($user, $password, $role = 'member', $sendEmail = false)
          {
        try {
            DB::transaction(function () use ($user, $password, $role, $sendEmail) {
                $this->userMeta->firstOrCreate([
                    'user_id' => $user->id
                ]);

                $this->assignRole($role, $user->id);

                if ($sendEmail) {
                    event(new UserRegisteredEmail($user, $password));
                }
            });

            $this->setAndSendUserActivationToken($user);

            return $user;
        } catch (Exception $e) {
            throw new Exception("We were unable to generate your profile, please try again later.", 1);
        }
    }
@eldersoon eldersoon reopened this Aug 30, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant