public function LogMessage::getUser in File Log 8
Same name and namespace in other branches
- 2.0.x src/LogMessage.php \Drupal\filelog\LogMessage::getUser()
Get the user who triggered the message.
Return value
\Drupal\user\UserInterface The user object.
File
- src/
LogMessage.php, line 233
Class
- LogMessage
- Represents a single log event.
Namespace
Drupal\filelogCode
public function getUser() : UserInterface {
if (!$this->user) {
$this->user = User::load($this->context['uid']);
}
return $this->user;
}