Validate and sanitize in node.js