Skip to content

Commit 3dab938

Browse files
wesalvaroIgorMinar
authored andcommitted
docs($timeout): set return type to Promise instead of *.
The cancel function accepts a Promise, but the timeout function fails to specify returning a Promise.
1 parent 7550f90 commit 3dab938

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ng/timeout.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ function $TimeoutProvider() {
2929
* @param {number=} [delay=0] Delay in milliseconds.
3030
* @param {boolean=} [invokeApply=true] If set to false skips model dirty checking, otherwise
3131
* will invoke `fn` within the {@link ng.$rootScope.Scope#$apply $apply} block.
32-
* @returns {*} Promise that will be resolved when the timeout is reached. The value this
32+
* @returns {Promise} Promise that will be resolved when the timeout is reached. The value this
3333
* promise will be resolved with is the return value of the `fn` function.
3434
*/
3535
function timeout(fn, delay, invokeApply) {

0 commit comments

Comments
 (0)