Skip to content

Commit

Permalink
fix: use ResourceOptions#sort#direction in search action, if defined
Browse files Browse the repository at this point in the history
  • Loading branch information
dziraf authored Mar 14, 2024
1 parent 26edaf3 commit 8ead779
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/backend/actions/search/search-action.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export const SearchAction: Action<SearchActionResponse> = {

const {
sortBy = decorated.options?.sort?.sortBy || titlePropertyName,
direction = 'asc',
direction = decorated.options?.sort?.direction || 'asc',
filters: customFilters = {},
perPage = 50,
page = 1,
Expand Down

0 comments on commit 8ead779

Please sign in to comment.