You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Form::__construct() expects the first parameter to be a Controller (maybe it should be type-hinted?): the class relies on methods such as Controller::redirectBack(). However, GridFieldDetailForm_ItemRequest, which is not an instance of Controller, is passed as the $controller argument here, which can cause fatal errors. For example, if the security token is invalid the form is unable to redirect back and preserve the form data.
The text was updated successfully, but these errors were encountered:
Well, that instance of sending the ItemRequest needs to be fixed. I'm not a fan of FORCING the parameters to be specific class types (it's not a hint, it's an enforcement)
Today, I received an error email that seems to be related to this issue:
[Error] Uncaught Exception: Object->__call(): the method 'redirectback' does not exist on 'GridFieldDetailForm_ItemRequest'
/var/www-capistrano/silverstripe/releases/B/docroot/framework/core/Object.php:763
Form::__construct()
expects the first parameter to be aController
(maybe it should be type-hinted?): the class relies on methods such asController::redirectBack()
. However,GridFieldDetailForm_ItemRequest
, which is not an instance ofController
, is passed as the$controller
argument here, which can cause fatal errors. For example, if the security token is invalid the form is unable to redirect back and preserve the form data.The text was updated successfully, but these errors were encountered: