Skip to content

Commit

Permalink
chore(executeOperation): use owner symbol instead of owner obj
Browse files Browse the repository at this point in the history
  • Loading branch information
daprahamian authored and mbroadst committed Mar 19, 2018
1 parent b60ac28 commit 02729dc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
},
"globals": {
"Promise": true,
"Set": true
"Set": true,
"Symbol": true
},
"parserOptions": {
"ecmaVersion": 2017
Expand Down
2 changes: 1 addition & 1 deletion lib/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ const executeOperation = (topology, operation, args, options) => {
if (!options.skipSessions && topology.hasSessionSupport()) {
opOptions = args[args.length - 2];
if (opOptions == null || opOptions.session == null) {
owner = {};
owner = Symbol();
session = topology.startSession({ owner });
const optionsIndex = args.length - 2;
args[optionsIndex] = Object.assign({}, args[optionsIndex], { session: session });
Expand Down

0 comments on commit 02729dc

Please sign in to comment.