adonis-mqcontroller
Advanced tools
Comparing version 1.0.4 to 1.0.5
'use strict' | ||
const _ = require('lodash') | ||
const _ = use('lodash') | ||
const {ObjectId} = use('mongodb') | ||
class BaseController { | ||
@@ -86,4 +87,4 @@ constructor (Repository) { | ||
else if(typeOfField == "objectid"){ | ||
typeAllowed = ObjectID.isValid(data[fieldName]) | ||
if(typeAllowed) data[fieldName] = new ObjectID(data[fieldName]) | ||
typeAllowed = ObjectId.isValid(data[fieldName]) | ||
if(typeAllowed) data[fieldName] = new ObjectId(data[fieldName]) | ||
} | ||
@@ -90,0 +91,0 @@ } |
{ | ||
"name": "adonis-mqcontroller", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"private": false, | ||
@@ -5,0 +5,0 @@ "main": "./BaseController.js", |
7997
94