RSS Feed/News Passing more extraParams to user spam checker from registration service requires overwriting whole method

Status
Not open for further replies.

ENXF NET

Administrator
Staff member
Administrator
Moderator
+Lifetime VIP+
S.V.I.P.S Member
S.V.I.P Member
V.I.P Member
Collaborate
Registered
Joined
Nov 13, 2018
Messages
33,772
Points
823

Reputation:

\XF\Service\User\Registration::checkForSpam
PHP:

Code:
public function checkForSpam()
{
    $user = $this->user;

$userChecker = $this->app->spam()->userChecker();
    $userChecker->check($user, ['preRegActionKey' => $this->preRegActionKey]);

Could this be changed so the second parameter for check is taken from a method istead of being hardcoded?

Eg. smth. like
PHP:

Code:
public function checkForSpam()
{
    $user = $this->user;

$userChecker = $this->app->spam()->userChecker()...

Read more

Continue reading...
 
Status
Not open for further replies.
Top