Skip to content

Commit cace8ba

Browse files
authored
fix: set maxVersions default value not work (#7)
Signed-off-by: Kevin Cui <bh@bugs.cc>
1 parent 595fef8 commit cace8ba

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/operator/batch-get-row.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ export class BatchGetRow {
8383
}
8484

8585
if (!table.maxVersions && !table.timeRange) {
86-
table.maxVersions = 1;
86+
p.maxVersions = 1;
8787
}
8888

8989
return p;

src/operator/get-range.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ export class GetRange {
7878
}
7979

8080
if (!options.maxVersions && !options.timeRange) {
81-
options.maxVersions = 1;
81+
payload.maxVersions = 1;
8282
}
8383

8484
return ProtoGetRangeRequest.encode(ProtoGetRangeRequest.create(payload)).finish();

src/operator/get-row.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export class GetRow {
7272
}
7373

7474
if (!options.maxVersions && !options.timeRange) {
75-
options.maxVersions = 1;
75+
payload.maxVersions = 1;
7676
}
7777

7878
return ProtoGetRowRequest.encode(ProtoGetRowRequest.create(payload)).finish();

0 commit comments

Comments
 (0)