app.js updated with rigor