add check for initial object in app.js