mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #10513 from TheBnl/patch-3
Member updateName extension hook
This commit is contained in:
commit
7fd8ed165d
@ -1217,7 +1217,9 @@ class Member extends DataObject
|
||||
*/
|
||||
public function getName()
|
||||
{
|
||||
return ($this->Surname) ? trim($this->FirstName . ' ' . $this->Surname) : $this->FirstName;
|
||||
$name = ($this->Surname) ? trim($this->FirstName . ' ' . $this->Surname) : $this->FirstName;
|
||||
$this->extend('updateName', $name);
|
||||
return $name;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user