Remove rootScope dependency in controllers.

Intead watch when the login state changes to tigger page updates.
Add some extra error checking for the statistics pages.