Skip to content

Commit

Permalink
refactor(model): correct casing of search mode
Browse files Browse the repository at this point in the history
  • Loading branch information
KennethTrecy committed Sep 17, 2023
1 parent dd430a2 commit e5a2779
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/Models/BaseResourceModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ abstract class BaseResourceModel extends Model implements FabricatorModel, Owned
abstract public function limitSearchToUser(BaseResourceModel $query_builder, User $user);

public function filterList(BaseResourceModel $query_builder, array $options) {
$filter_search_mode = $options["search_mode"] ?? SEARCH_NORMALLY;
$filter_search_mode = strtoupper($options["search_mode"] ?? SEARCH_NORMALLY);

if (in_array($filter_search_mode, $this->available_search_modes, true)) {
return $query_builder->getSearchQuery($filter_search_mode);
Expand Down

0 comments on commit e5a2779

Please sign in to comment.