nodecellar
nodecellar copied to clipboard
Much more robust API (may help a lot of people)
Christophe: LOVE your tutorials! I have learned quite a bit! I wanted to give back by improving your wines api a bit -
- Returns proper HTML response codes
- Much faster! (because it returns proper response codes browser doesn't wait...)
- Can't crash the app by sending bad data (checks what you send it)
- Makes sure the browser won't cache the data (problem solved)
- If it can't update or delete an item you now will be notified properly
- res.send changed to res.json
Christophe - sorry I put this in the master branch - kind of new to all this. Cheers.