NodeJS : Checking and updating passwords with passport-local and bcrypt in node.js