Skip to content

Commit

Permalink
[5.4] Use custom auth identifier column for "getAuthIdentifier" if se…
Browse files Browse the repository at this point in the history
…t. (#19038)

* [5.4] Return value from custom auth identifier column, if set.

* Update Authenticatable.php
  • Loading branch information
DFurnes authored and taylorotwell committed May 3, 2017
1 parent 4624b89 commit 4ce1926
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Illuminate/Auth/Authenticatable.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function getAuthIdentifierName()
*/
public function getAuthIdentifier()
{
return $this->getKey();
return $this->{$this->getAuthIdentifierName()};
}

/**
Expand Down

0 comments on commit 4ce1926

Please sign in to comment.