mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #7783 from emteknetnz/emteknetnz-member-id-cast
Ensure currentUserID() returns an int
This commit is contained in:
commit
83de0a0d36
@ -894,7 +894,7 @@ class Member extends DataObject implements TemplateGlobalProvider {
|
||||
$id = Session::get("loggedInAs");
|
||||
}
|
||||
|
||||
return is_numeric($id) ? $id : 0;
|
||||
return is_numeric($id) ? (int) $id : 0;
|
||||
}
|
||||
private static $_already_tried_to_auto_log_in = false;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user