From 5f31f36a175a4e722db12c7af9c150adf737e8fe Mon Sep 17 00:00:00 2001 From: Damian Mooyman Date: Mon, 20 Jun 2016 09:54:33 +1200 Subject: [PATCH] BUG Prevent strstr showing warning on array $value Fixes #481 --- code/formfields/UserFormsCheckboxSetField.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/formfields/UserFormsCheckboxSetField.php b/code/formfields/UserFormsCheckboxSetField.php index f8f7d14..1fd5954 100644 --- a/code/formfields/UserFormsCheckboxSetField.php +++ b/code/formfields/UserFormsCheckboxSetField.php @@ -46,7 +46,7 @@ class UserFormsCheckboxSetField extends CheckboxSetField { $previous = $value = $this->Value(); - if (strstr($value, ",")) { + if (is_string($value) && strstr($value, ",")) { $value = explode(",", $value); }