Skip to content

Commit

Permalink
Update OAuthController.php
Browse files Browse the repository at this point in the history
  • Loading branch information
warcooft authored May 16, 2024
1 parent 9c4d783 commit 8f1c0e0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Controllers/OAuthController.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ public function callBack(): RedirectResponse

// Create new user if credentials not exist or let users register themselves
if ($this->checkExistenceUser($find) === false) {

// Check config setting first to see if it can register automatically ?
if (config('ShieldOAuthConfig')->oauthConfigs[$oauthName]['allow_register'] === false) {
return redirect()->to(config('Auth')->logoutRedirect())->with('error', lang('ShieldOAuthLang.Callback.account_not_found'));
Expand Down

0 comments on commit 8f1c0e0

Please sign in to comment.