Skip to content

Commit

Permalink
Update snippet.formitischecked.php
Browse files Browse the repository at this point in the history
Because without this checks you will get an error when it's not an array?? But why at all?? You can only add this one to one single placeholder right? it isn't an array I guess?
  • Loading branch information
Bert Oost committed Apr 10, 2013
1 parent 18dfd67 commit c0c6414
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
$output = ' checked="checked"';
}
$input = $modx->fromJSON($input);
if (in_array($options,$input)) {
if (!empty($input) && is_array($input) && in_array($options,$input)) {
$output = ' checked="checked"';
}
return $output;

0 comments on commit c0c6414

Please sign in to comment.