app.js changed to work with new architecture