mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-04-14 01:24:26 +00:00
angularjs: allow $q.when to be called w/o args
The current definition does not cover the case that the input type is void.
This commit is contained in:
6
angularjs/angular.d.ts
vendored
6
angularjs/angular.d.ts
vendored
@@ -565,6 +565,12 @@ declare module ng {
|
||||
* @param value Value or a promise
|
||||
*/
|
||||
when<T>(value: T): IPromise<T>;
|
||||
/**
|
||||
* Wraps an object that might be a value or a (3rd party) then-able promise into a $q promise. This is useful when you are dealing with an object that might or might not be a promise, or if the promise comes from a source that can't be trusted.
|
||||
*
|
||||
* @param value Value or a promise
|
||||
*/
|
||||
when(): IPromise<void>;
|
||||
}
|
||||
|
||||
interface IPromise<T> {
|
||||
|
||||
Reference in New Issue
Block a user