Skip to content

Commit 4ce1926

Browse files
DFurnestaylorotwell
authored andcommitted
[5.4] Use custom auth identifier column for "getAuthIdentifier" if set. (#19038)
* [5.4] Return value from custom auth identifier column, if set. * Update Authenticatable.php
1 parent 4624b89 commit 4ce1926

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Illuminate/Auth/Authenticatable.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public function getAuthIdentifierName()
2828
*/
2929
public function getAuthIdentifier()
3030
{
31-
return $this->getKey();
31+
return $this->{$this->getAuthIdentifierName()};
3232
}
3333

3434
/**

0 commit comments

Comments
 (0)