public function findOneBy($property) { return array_filter($this->getAllPreferences(), function ($pref) use($property) { return $pref['option'] === $property; }); }