created app/utils and moved formatting functions to database.js file