docs: fix shadow variable in tutorial example (#28499)

PR Close #28499
This commit is contained in:
LHearen 2019-02-02 18:01:45 +08:00 committed by Matias Niemelä
parent 3d522716c4
commit 1e5012b2cc
1 changed files with 1 additions and 1 deletions

View File

@ -97,7 +97,7 @@ export class HeroService {
/** POST: add a new hero to the server */
addHero (hero: Hero): Observable<Hero> {
return this.http.post<Hero>(this.heroesUrl, hero, httpOptions).pipe(
tap((hero: Hero) => this.log(`added hero w/ id=${hero.id}`)),
tap((newHero: Hero) => this.log(`added hero w/ id=${newHero.id}`)),
catchError(this.handleError<Hero>('addHero'))
);
}