From 71e88a8c3c9d87a763fac6d9ccff7406a27f6b57 Mon Sep 17 00:00:00 2001 From: Dzmitry Shylovich Date: Sat, 17 Dec 2016 02:21:58 +0300 Subject: [PATCH] refactor(core): fix typo (#13515) Closes #13512 --- modules/@angular/core/src/application_ref.ts | 6 +++--- tools/public_api_guard/core/index.d.ts | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/@angular/core/src/application_ref.ts b/modules/@angular/core/src/application_ref.ts index 3defc16114..da93fd0f88 100644 --- a/modules/@angular/core/src/application_ref.ts +++ b/modules/@angular/core/src/application_ref.ts @@ -94,13 +94,13 @@ export function createPlatform(injector: Injector): PlatformRef { * @experimental APIs related to application bootstrap are currently under review. */ export function createPlatformFactory( - parentPlaformFactory: (extraProviders?: Provider[]) => PlatformRef, name: string, + parentPlatformFactory: (extraProviders?: Provider[]) => PlatformRef, name: string, providers: Provider[] = []): (extraProviders?: Provider[]) => PlatformRef { const marker = new OpaqueToken(`Platform: ${name}`); return (extraProviders: Provider[] = []) => { if (!getPlatform()) { - if (parentPlaformFactory) { - parentPlaformFactory( + if (parentPlatformFactory) { + parentPlatformFactory( providers.concat(extraProviders).concat({provide: marker, useValue: true})); } else { createPlatform(ReflectiveInjector.resolveAndCreate( diff --git a/tools/public_api_guard/core/index.d.ts b/tools/public_api_guard/core/index.d.ts index b32d844f9b..8851d4e517 100644 --- a/tools/public_api_guard/core/index.d.ts +++ b/tools/public_api_guard/core/index.d.ts @@ -305,7 +305,7 @@ export interface ContentChildrenDecorator { export declare function createPlatform(injector: Injector): PlatformRef; /** @experimental */ -export declare function createPlatformFactory(parentPlaformFactory: (extraProviders?: Provider[]) => PlatformRef, name: string, providers?: Provider[]): (extraProviders?: Provider[]) => PlatformRef; +export declare function createPlatformFactory(parentPlatformFactory: (extraProviders?: Provider[]) => PlatformRef, name: string, providers?: Provider[]): (extraProviders?: Provider[]) => PlatformRef; /** @stable */ export declare const CUSTOM_ELEMENTS_SCHEMA: SchemaMetadata;