File manager - Edit - /var/www/payraty/helpdesk/common/Auth/Traits/HasDisplayNameAttribute.php
Back
<?php namespace Common\Auth\Traits; trait HasDisplayNameAttribute { /** * Compile user display name from available attributes. * * @return string */ public function getDisplayNameAttribute() { if ($this->username) { return $this->username; } else if ($this->first_name && $this->last_name) { return $this->first_name.' '.$this->last_name; } else if ($this->first_name) { return $this->first_name; } else if ($this->last_name) { return $this->last_name; } else { return explode('@', $this->email)[0]; } } }
| ver. 1.4 |
Github
|
.
| PHP 8.3.30 | Generation time: 0.01 |
proxy
|
phpinfo
|
Settings