File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ const executeOperation = require('../operations/execute_operation');
1111const Readable = require ( 'stream' ) . Readable ;
1212const SUPPORTS = require ( '../utils' ) . SUPPORTS ;
1313const MongoDBNamespace = require ( '../utils' ) . MongoDBNamespace ;
14+ const mergeOptions = require ( '../utils' ) . mergeOptions ;
1415const OperationBase = require ( '../operations/operation' ) . OperationBase ;
1516
1617const BSON = retrieveBSON ( ) ;
@@ -207,7 +208,9 @@ class CoreCursor extends Readable {
207208 * @return {Cursor }
208209 */
209210 clone ( ) {
210- return this . topology . cursor ( this . ns , this . cmd , this . options ) ;
211+ const clonedOptions = mergeOptions ( { } , this . options ) ;
212+ delete clonedOptions . session ;
213+ return this . topology . cursor ( this . ns , this . cmd , clonedOptions ) ;
211214 }
212215
213216 /**
You can’t perform that action at this time.
0 commit comments