Remove references to $rootScope.Shared & .Content in non-view code.

Instead, have them request services that return them so tests don’t need to prepare special state.
This commit is contained in:
Andrew Bloomgarden
2014-01-12 15:05:15 -08:00
parent 77801e458e
commit dc368bb652
14 changed files with 65 additions and 58 deletions

View File

@@ -1,8 +1,7 @@
habitrpg.controller("InventoryCtrl", ['$rootScope', '$scope', '$window', 'User',
function($rootScope, $scope, $window, User) {
habitrpg.controller("InventoryCtrl", ['$rootScope', '$scope', '$window', 'User', 'Content',
function($rootScope, $scope, $window, User, Content) {
var user = User.user;
var Content = $rootScope.Content;
// convenience vars since these are accessed frequently
@@ -135,4 +134,4 @@ habitrpg.controller("InventoryCtrl", ['$rootScope', '$scope', '$window', 'User',
$scope.closeQuest();
}
}
]);
]);