[bug] $and AND $or with one value should work
JimmyDaddy opened this issue · comments
JimmyDaddy commented
Model.find({
where: {
type: { $and: [ 'GOOD' ] }
}
});
this will throw Cannot read property 'type' of undefined
at src/drivers/abstract/spellbook.js:184:20
Chen Yangjian commented
What is the expected behavior? ignore the $and
or $or
operator?
JimmyDaddy commented
What is the expected behavior? ignore the
$and
or$or
operator?
I think so, or is there another proper way?
Chen Yangjian commented
or throw an error telling the user that the operator didn't receive enough arguments.
personally I'd go with ignore.