Fix for spam checker
This commit is contained in:
parent
ab2c819423
commit
8a2d6c2dd5
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