documented controller.js file