Fix for spam checker
This commit is contained in:
parent
3ce6412a63
commit
e058c93b36
1 changed files with 3 additions and 1 deletions
|
|
@ -129,7 +129,9 @@ class AccountRepository
|
|||
private function checkForSpammer()
|
||||
{
|
||||
$ip = Request::getClientIp();
|
||||
$count = Account::whereIp($ip)->count();
|
||||
$count = Account::whereIp($ip)->whereHas('users', function ($query) {
|
||||
$query->whereConfirmed(true);
|
||||
})->count();
|
||||
|
||||
if ($count > 1 && $errorEmail = env('ERROR_EMAIL')) {
|
||||
\Mail::raw($ip, function ($message) use ($ip, $errorEmail) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue