var userSchema = new Schema({ email: String , passwordHash: String }); userSchema.pre('validate', function(next) { if (this.password === this.passwordConfirm) { this.set('passwordHash', hash(this.password); this.set('passwordHash',undefined); this.set('passwordConfirm',undefined); // How do I prevent this.password and this.passwordConfirm // to be save into DB? } next() }); var User = db.model('User', userSchema); var user = new User() user.init({ email: 'hello@example.com' , password: 'password' , confirmPassword: 'password' }); user.save(function(err) { console.log(!!err ? 'error' : 'saved'); }); function hash(str) { return str+'hashed' }