mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-18 04:26:01 +00:00
mongoid fix
This commit is contained in:
@@ -9,7 +9,7 @@ const Cursor = require('mongodb').Cursor;
|
||||
const createBulkInsertStream = require('./createBulkInsertStream');
|
||||
|
||||
function transformMongoData(row) {
|
||||
return _.mapValues(row, (v) => (v && v.constructor && v.constructor.name == 'ObjectID' ? { $oid: v.toString() } : v));
|
||||
return _.mapValues(row, (v) => (v && v.constructor == ObjectId ? { $oid: v.toString() } : v));
|
||||
}
|
||||
|
||||
function readCursor(cursor, options) {
|
||||
|
||||
Reference in New Issue
Block a user