diff --git a/src/ORM/FieldType/DBBoolean.php b/src/ORM/FieldType/DBBoolean.php index 5e2ddc3a25b..bc74dc9a08a 100644 --- a/src/ORM/FieldType/DBBoolean.php +++ b/src/ORM/FieldType/DBBoolean.php @@ -62,13 +62,13 @@ public function scaffoldSearchField($title = null) { $anyText = _t(__CLASS__ . '.ANY', 'Any'); $source = [ + '' => $anyText, 1 => _t(__CLASS__ . '.YESANSWER', 'Yes'), 0 => _t(__CLASS__ . '.NOANSWER', 'No') ]; - $field = new DropdownField($this->name, $title, $source); - $field->setEmptyString("($anyText)"); - return $field; + return (new DropdownField($this->name, $title, $source)) + ->setEmptyString($anyText); } public function nullValue()