user management linked to $rootScope for better $apply()