diff --git a/packages/common/upgrade/src/utils.ts b/packages/common/upgrade/src/utils.ts index 97fcc594c18e2..48cba8e2fee97 100644 --- a/packages/common/upgrade/src/utils.ts +++ b/packages/common/upgrade/src/utils.ts @@ -31,7 +31,7 @@ export function isAnchor(el: (Node & ParentNode) | Element | null): el is HTMLAn return (el).href !== undefined; } -export function isPromise(obj: any): obj is Promise { +export function isPromise(obj: any): obj is Promise { // allow any Promise/A+ compliant thenable. // It's up to the caller to ensure that obj.then conforms to the spec return !!obj && typeof obj.then === 'function'; diff --git a/packages/compiler/src/util.ts b/packages/compiler/src/util.ts index 01819f7225ffe..789219e115234 100644 --- a/packages/compiler/src/util.ts +++ b/packages/compiler/src/util.ts @@ -214,7 +214,7 @@ export function resolveForwardRef(type: any): any { /** * Determine if the argument is shaped like a Promise */ -export function isPromise(obj: any): obj is Promise { +export function isPromise(obj: any): obj is Promise { // allow any Promise/A+ compliant thenable. // It's up to the caller to ensure that obj.then conforms to the spec return !!obj && typeof obj.then === 'function'; diff --git a/packages/core/src/util/lang.ts b/packages/core/src/util/lang.ts index b6631e84d07e1..d69c39a1465ec 100644 --- a/packages/core/src/util/lang.ts +++ b/packages/core/src/util/lang.ts @@ -11,7 +11,7 @@ import {Observable} from 'rxjs'; /** * Determine if the argument is shaped like a Promise */ -export function isPromise(obj: any): obj is Promise { +export function isPromise(obj: any): obj is Promise { // allow any Promise/A+ compliant thenable. // It's up to the caller to ensure that obj.then conforms to the spec return !!obj && typeof obj.then === 'function';