fix controller object issue in angular 1.2