refactor: Add explict type to allow RxJS to be updated

While trying to sync RxJS into google3 an issue came up around the code in question, where TypeScript is unable to properly infer the type. Adding this explicit type resolves the issue.
This commit is contained in:
Ben Lesh 2019-06-12 14:58:24 -07:00 committed by Keen Yee Liau
parent 4ad0fb73c3
commit caeaa53e1a

View File

@ -17,6 +17,7 @@ import {
parseJson,
schema,
} from '../../json';
import { SchemaValidatorResult } from '../../json/schema/interface';
import {
Path,
basename,
@ -342,7 +343,7 @@ export class Workspace {
return this._registry.compile(schemaJson).pipe(
concatMap(validator => validator(contentJsonCopy)),
concatMap(validatorResult => {
concatMap((validatorResult: SchemaValidatorResult) => {
if (validatorResult.success) {
return of(contentJsonCopy as T);
} else {