added string trim to app.js