Skip to content

Commit

Permalink
fix(types): allow mixed arrays in numeric and tag filters (#1395)
Browse files Browse the repository at this point in the history
  • Loading branch information
eliasnorrby committed Feb 24, 2022
1 parent e8f08ed commit 326c833
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/client-search/src/types/DeleteByFiltersOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ export type DeleteByFiltersOptions = {
/**
* Filter on numeric attributes.
*/
readonly numericFilters?: string | readonly string[] | ReadonlyArray<readonly string[]>;
readonly numericFilters?: string | readonly string[] | ReadonlyArray<readonly string[] | string>;

/**
* Filter hits by tags. tagFilters is a different way of filtering, which relies on the _tags
* attribute. It uses a simpler syntax than filters. You can use it when you want to do
* simple filtering based on tags.
*/
readonly tagFilters?: string | readonly string[] | ReadonlyArray<readonly string[]>;
readonly tagFilters?: string | readonly string[] | ReadonlyArray<readonly string[] | string>;

/**
* Search for entries around a central geolocation, enabling a geo search within a circular area.
Expand Down
4 changes: 2 additions & 2 deletions packages/client-search/src/types/SearchOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ export type SearchOptions = {
/**
* Filter on numeric attributes.
*/
readonly numericFilters?: string | readonly string[] | ReadonlyArray<readonly string[]>;
readonly numericFilters?: string | readonly string[] | ReadonlyArray<readonly string[] | string>;

/**
* Filter hits by tags. tagFilters is a different way of filtering, which relies on the _tags
* attribute. It uses a simpler syntax than filters. You can use it when you want to do
* simple filtering based on tags.
*/
readonly tagFilters?: string | readonly string[] | ReadonlyArray<readonly string[]>;
readonly tagFilters?: string | readonly string[] | ReadonlyArray<readonly string[] | string>;

/**
* Determines how to calculate the total score for filtering.
Expand Down

0 comments on commit 326c833

Please sign in to comment.