Skip to content

Commit

Permalink
Merge pull request #338 from danswiser/patch-1
Browse files Browse the repository at this point in the history
Don't use hardcoded primary key name
  • Loading branch information
bezhanSalleh authored Mar 28, 2024
2 parents 71dc9cd + 7b6ee68 commit 6819839
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Commands/MakeShieldSuperAdminCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public function handle(): int
['ID', 'Name', 'Email', 'Roles'],
static::getUserModel()::with('roles')->get()->map(function (Authenticatable $user) {
return [
'id' => $user->getAttribute('id'),
'id' => $user->getKey(),
'name' => $user->getAttribute('name'),
'email' => $user->getAttribute('email'),
/** @phpstan-ignore-next-line */
Expand Down

0 comments on commit 6819839

Please sign in to comment.