Skip to content
This repository was archived by the owner on Sep 5, 2025. It is now read-only.

Commit 43b1685

Browse files
committed
Fixed bug
1 parent b682b97 commit 43b1685

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

lib/txn.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ var Txn = (function () {
5151
start_ts: 0,
5252
keys: [],
5353
preds: [],
54-
readOnly: options.readOnly || false,
55-
bestEffort: options.bestEffort || false
54+
readOnly: options && options.readOnly,
55+
bestEffort: options && options.bestEffort
5656
};
5757
}
5858
Txn.prototype.query = function (q, options) {

src/txn.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ export class Txn {
3939
start_ts: 0,
4040
keys: [],
4141
preds: [],
42-
readOnly: options.readOnly || false,
43-
bestEffort: options.bestEffort || false
42+
readOnly: options && options.readOnly,
43+
bestEffort: options && options.bestEffort
4444
};
4545
}
4646

0 commit comments

Comments
 (0)