Example #1
0
 /**
  * Invoke
  * @return string|null
  */
 public function __invoke()
 {
     return $this->ipService->getIp();
 }
Example #2
0
 /**
  * Return detected IP address
  * @return string
  */
 public function __toString()
 {
     $ip = $this->ipService->getIp();
     return null === $ip ? '' : $ip;
 }