cgross/angular-busy — pull request #35 by johngeorgewright (2014-07-03 13:37:40+00:00)
Title: Added compatibility for an array as a promise

Until now we could only except an object with a promise property *or* an array of promises. What I need to achieve is using angular-busy with an array **with** a promise property.

This commonly happens when using angular's `$resource` service and the server responds with an array rather than an object.

```js
function BlogFactory($resource) {
return $resource.service('/blogs');
}

function BlogCtrl(Blog, $scope) {
$scope.blogs = Blogs.query();
}
```

When we use syntax like this we get an array with a promise property. A bit like doing this:

```js
$scope.blogs = [];
$scope.blogs.$promise = $q.defer().promise;
```