Refactoring angularjs code.