Fixed missing dependency on $rootScope.