Fixed Contact form Guest email is not submit email to spam checker

Xon

Well-known member
Affected version
2.1.1
The submitted email address for a guest user is not pushed into the spam checker in XF\Service\Contact::checkForSpam

Instead of;
PHP:
$user = $this->fromUser ?: $this->repository('XF:User')->getGuestUser($this->fromName);

Something like;
PHP:
if (!$this->fromUser)
{
    $user = $this->repository('XF:User')->getGuestUser($this->fromName);
    $user->setAsSaved('email', $this->fromEmail);
}
else
{
    $user = $this->fromUser;
}
 
Last edited:
Thank you for reporting this issue. It has now been resolved and we are aiming to include it in a future XF release (2.1.2).

Change log:
Submit user's email address when checking for spam at the contact form.
Any changes made as a result of this issue being resolved may not be rolled out here until later.
 
Back
Top Bottom