Update public/js/main.js

Modification to my main.js based on the backbone tutorials website