Merge pull request #7756 from dhensby/pulls/4.0/fix-bad-request-form-handlers

Forms with FormHandlers don't have access to current request object
This commit is contained in:
Robbie Averill 2018-01-16 23:32:00 +13:00 committed by GitHub
commit a8c156ae98
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -228,6 +228,7 @@ class FormRequestHandler extends RequestHandler
// First, try a handler method on the controller (has been checked for allowed_actions above already)
$controller = $this->form->getController();
if ($controller && $controller->hasMethod($funcName)) {
$controller->setRequest($request);
return $controller->$funcName($vars, $this->form, $request, $this);
}