Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function find(obj) {
- //what argument do I have?
- console.log(obj);
- }
- var req = {
- body: {
- username: "peat",
- password: "123456"
- }
- }
- //What you're doing
- find(req.body.username);
- //What must be done
- find({username: req.body.username});
- find(req.body);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement