Skip to content

Commit 94d93fc

Browse files
committed
Add bot IP to CheckIfBotIsReal error throw
1 parent 738b8a2 commit 94d93fc

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Jobs/CheckIfBotIsReal.php

+3-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,9 @@ public function handle()
4949
}
5050

5151
if (is_null($found_bot_key)) {
52-
throw new \InvalidArgumentException("I did not found \"{$this->client->userAgent}\" key");
52+
$ip = !empty($this->client) && !empty($this->client->ip) ? ", IP: {$this->client->ip}." : ". The IP was not recovered.";
53+
54+
throw new \InvalidArgumentException("I did not found \"{$this->client->userAgent}\" key{$ip}");
5355
}
5456

5557
// Lets remove from the pending list

0 commit comments

Comments
 (0)