[TASK] Refactorings based on the angular-styleguide

Check out the [angular-styleguide](https://github.com/johnpapa/angularjs-styleguide). More is coming.