File tree Expand file tree Collapse file tree 1 file changed +0
-33
lines changed Expand file tree Collapse file tree 1 file changed +0
-33
lines changed Original file line number Diff line number Diff line change @@ -2587,39 +2587,6 @@ Query.prototype._findOneAndRemove = async function() {
2587
2587
return this . _collection . findOneAndDelete ( conds , options ) ;
2588
2588
} ;
2589
2589
2590
- /**
2591
- * Wrap callback to add tracing
2592
- *
2593
- * @param {Function } callback
2594
- * @param {Object } [queryInfo]
2595
- * @api private
2596
- */
2597
- Query . prototype . _wrapCallback = function ( method , callback , queryInfo ) {
2598
- const traceFunction = this . _traceFunction || Query . traceFunction ;
2599
-
2600
- if ( traceFunction ) {
2601
- queryInfo . collectionName = this . _collection . collectionName ;
2602
-
2603
- const traceCallback = traceFunction &&
2604
- traceFunction . call ( null , method , queryInfo , this ) ;
2605
-
2606
- const startTime = new Date ( ) . getTime ( ) ;
2607
-
2608
- return function wrapperCallback ( err , result ) {
2609
- if ( traceCallback ) {
2610
- const millis = new Date ( ) . getTime ( ) - startTime ;
2611
- traceCallback . call ( null , err , result , millis ) ;
2612
- }
2613
-
2614
- if ( callback ) {
2615
- callback . apply ( null , arguments ) ;
2616
- }
2617
- } ;
2618
- }
2619
-
2620
- return callback ;
2621
- } ;
2622
-
2623
2590
/**
2624
2591
* Add trace function that gets called when the query is executed.
2625
2592
* The function will be called with (method, queryInfo, query) and
You can’t perform that action at this time.
0 commit comments