fix: checking for html content-type
This commit is contained in:
parent
bb53e88a4e
commit
4a430b2701
1 changed files with 4 additions and 1 deletions
|
@ -220,7 +220,10 @@ export class HttpService implements HttpServiceInterface {
|
|||
}
|
||||
|
||||
private responseShouldNotBeDecorated(serviceResponse: AxiosResponse): boolean {
|
||||
return serviceResponse.headers['content-type'].toLowerCase().includes('text/html')
|
||||
return (
|
||||
serviceResponse.headers['content-type'] !== undefined &&
|
||||
serviceResponse.headers['content-type'].toLowerCase().includes('text/html')
|
||||
)
|
||||
}
|
||||
|
||||
private applyResponseHeaders(serviceResponse: AxiosResponse, response: Response): void {
|
||||
|
|
Loading…
Reference in a new issue