added scope array to controller.js