Skip to content

Commit dd39294

Browse files
committed
update to final design doc
1 parent 7eb9332 commit dd39294

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

packages/search/lib/commands/CREATE.spec.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -443,17 +443,17 @@ describe('CREATE', () => {
443443
});
444444

445445
describe('Missing Values', () => {
446-
it('with ISNULL', () => {
446+
it('with INDEX_EMPTY', () => {
447447
assert.deepEqual(
448448
transformArguments('index', {
449449
field: {
450450
type: SchemaFieldTypes.TEXT,
451451
MISSING_VALUES: {
452-
IS_NULL: true
452+
INDEX_EMPTY: true
453453
}
454454
}
455455
}),
456-
['FT.CREATE', 'index', 'SCHEMA', 'field', 'TEXT', 'ISNULL']
456+
['FT.CREATE', 'index', 'SCHEMA', 'field', 'TEXT', 'INDEXEMPTY']
457457
);
458458
});
459459

@@ -463,11 +463,11 @@ describe('CREATE', () => {
463463
field: {
464464
type: SchemaFieldTypes.TEXT,
465465
MISSING_VALUES: {
466-
IS_MISSING: true
466+
INDEX_MISSING: true
467467
}
468468
}
469469
}),
470-
['FT.CREATE', 'index', 'SCHEMA', 'field', 'TEXT', 'ISMISSING']
470+
['FT.CREATE', 'index', 'SCHEMA', 'field', 'TEXT', 'INDEXMISSING']
471471
);
472472
});
473473
});

packages/search/lib/commands/index.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -190,21 +190,21 @@ export enum SchemaFieldTypes {
190190
}
191191

192192
export interface MissingValues {
193-
IS_NULL?: boolean;
194-
IS_MISSING?: boolean;
193+
INDEX_EMPTY?: boolean;
194+
INDEX_MISSING?: boolean;
195195
}
196196

197197
function pushMissingValues(args: RedisCommandArguments, missingValues?: MissingValues) {
198198
if (!missingValues) {
199199
return;
200200
}
201-
202-
if (missingValues.IS_MISSING) {
203-
args.push("ISMISSING");
201+
202+
if (missingValues.INDEX_EMPTY) {
203+
args.push("INDEXEMPTY");
204204
}
205205

206-
if (missingValues.IS_NULL) {
207-
args.push("ISNULL");
206+
if (missingValues.INDEX_MISSING) {
207+
args.push("INDEXMISSING");
208208
}
209209
}
210210

0 commit comments

Comments
 (0)