Skip to content

Commit

Permalink
[fix] - setting default values for auth_key and password_hash when au…
Browse files Browse the repository at this point in the history
…thorize via social network
  • Loading branch information
krivochenko committed Nov 8, 2017
1 parent b0a9bbb commit 9867a20
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions controllers/AuthController.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ public function successCallback($client)
}
if (!$user) {
$user = new User;
$user->generateAuthKey();
$user->password_hash = '';
$user->scenario = 'oauth';
$user->load($attributes);
$user->username = $this->findFreeUsername($user->username);
Expand Down

0 comments on commit 9867a20

Please sign in to comment.