Updated example/app.js to reflect working code