From 48ecb8d8f4d3c127cdbf1fcbc9f9a8d35b660a6a Mon Sep 17 00:00:00 2001 From: Jake Ovenden Date: Wed, 24 Feb 2016 15:13:00 +1300 Subject: [PATCH] added if statement to catch NULL validators --- admin/code/LeftAndMain.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/admin/code/LeftAndMain.php b/admin/code/LeftAndMain.php index 46fb86f5e..97f675452 100644 --- a/admin/code/LeftAndMain.php +++ b/admin/code/LeftAndMain.php @@ -1301,7 +1301,9 @@ class LeftAndMain extends Controller implements PermissionProvider { // The clientside (mainly LeftAndMain*.js) rely on ajax responses // which can be evaluated as javascript, hence we need // to override any global changes to the validation handler. - $form->setValidator($validator); + if($validator != NULL){ + $form->setValidator($validator); + } } else { $form->unsetValidator(); }