fixed login stuff, removed $cookies and resetting the rootscope in each controller