docs(http): fixed syntax error in AuthInterceptor example

This commit is contained in:
Daniel Bunte 2017-07-17 12:33:45 +02:00 committed by Alex Rickabaugh
parent 0bb8423df9
commit 7e72317059
1 changed files with 1 additions and 1 deletions

View File

@ -357,7 +357,7 @@ export class AuthInterceptor implements HttpInterceptor {
intercept(req: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> {
// Get the auth header from the service.
const authHeader: this.auth.getAuthorizationHeader();
const authHeader = this.auth.getAuthorizationHeader();
// Clone the request to add the new header.
const authReq = req.clone({headers: req.headers.set('Authorization', authHeader)});
// Pass on the cloned request instead of the original request.