提交 5bd6ebe2 编写于 作者: J Joao Moreno

move Promise back to TPromise in nfcall

related to #60163
上级 5300bc54
......@@ -657,7 +657,7 @@ export class RunOnceWorker<T> extends RunOnceScheduler {
export function nfcall(fn: Function, ...args: any[]): Promise<any>;
export function nfcall<T>(fn: Function, ...args: any[]): Promise<T>;
export function nfcall(fn: Function, ...args: any[]): any {
return new Promise((c, e) => fn(...args, (err: any, result: any) => err ? e(err) : c(result)));
return new TPromise((c, e) => fn(...args, (err: any, result: any) => err ? e(err) : c(result)));
}
export function ninvoke(thisArg: any, fn: Function, ...args: any[]): TPromise;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册