These are chat archives for Automattic/mongoose
thisunless I cast it .toObject();
This article shows how to do a username/password auth. It hashes the password on save, with a pre hook: http://blog.mongodb.org/post/32866457221/password-authentication-with-mongoose-part-1
it then says the 'pre' hook only gets called on save, not update.
What does one do when he wants to update a field that has a hook? re-save the whole document?