Skip to content

Commit 592714f

Browse files
committed
fix #1749 - FT.SEARCH SORTBY
1 parent 533dce0 commit 592714f

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

packages/search/lib/commands/SEARCH.ts

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ interface SearchOptions {
4848
SCORER?: string;
4949
// EXPLAINSCORE?: true; // TODO: WITHSCORES
5050
// PAYLOAD?: ;
51-
// SORTBY?: SortByOptions;
52-
MSORTBY?: SortByOptions | Array<SortByOptions>;
51+
SORTBY?: SortByOptions;
52+
// MSORTBY?: SortByOptions | Array<SortByOptions>;
5353
LIMIT?: {
5454
from: number | string;
5555
size: number | string;
@@ -149,15 +149,14 @@ export function transformArguments(
149149
// args.push('PAYLOAD', options.PAYLOAD);
150150
// }
151151

152-
// if (options?.SORTBY) {
153-
// args.push('SORTBY');
154-
// pushSortByArguments(args, options.SORTBY);
155-
// }
156-
157-
if (options?.MSORTBY) {
158-
pushSortByArguments(args, 'MSORTBY', options.MSORTBY);
152+
if (options?.SORTBY) {
153+
pushSortByArguments(args, 'SORTBY', options.SORTBY);
159154
}
160155

156+
// if (options?.MSORTBY) {
157+
// pushSortByArguments(args, 'MSORTBY', options.MSORTBY);
158+
// }
159+
161160
if (options?.LIMIT) {
162161
args.push(
163162
'LIMIT',

0 commit comments

Comments
 (0)