corrected app.js to work on uniserver