Skip to content

Commit

Permalink
Merge pull request #7092 from kioan000/3.4
Browse files Browse the repository at this point in the history
Only pass user's ID into Users::addRole()
  • Loading branch information
GwendolenLynch committed Oct 16, 2017
2 parents ad4ccdc + 2e4055e commit 29d8cee
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Users.php
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,9 @@ public function checkForRoot()
$this->app['logger.flash']->info(Trans::__('general.phrase.missing-root-jackpot'));

// If we reach this point, there is no user 'root'. We promote the current user.
return $this->addRole($this->getCurrentUser(), 'root');
$user = $this->getCurrentUser();

return $this->addRole($user['id'], 'root');
}

/**
Expand Down

0 comments on commit 29d8cee

Please sign in to comment.