What method is used to unset a key in MongoDB with Waterline ORM?
Consider the following document:
{
name : 'brian',
age : 29
}
Getting the user is no problem:
var users = Users.findOne({ name : 'brian' }).exec(cb);
I would like age to simply go away. I've tried the following to accomplish this:
user.age = undefined;
user.save();
user.age = null;
user.save();
delete user.age;
user.save();
None seem to work. #1 sets it to null, #2 sets it to null, #3 leaves the original value.
Thanks.