You are here

public function LogMessage::getIp in File Log 8

Same name and namespace in other branches
  1. 2.0.x src/LogMessage.php \Drupal\filelog\LogMessage::getIp()

Get the IP that triggered the message.

Return value

string The IP.

File

src/LogMessage.php, line 187

Class

LogMessage
Represents a single log event.

Namespace

Drupal\filelog

Code

public function getIp() : string {
  return $this->context['ip'] ?: '0.0.0.0';
}