From 4c503a417bb414dd6d275cdd555dafb63fd45fd5 Mon Sep 17 00:00:00 2001 From: kukhariev Date: Sun, 28 May 2023 10:01:27 +0300 Subject: [PATCH] chore(app): correct header check --- src/app/service-way/service-way.component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/service-way/service-way.component.ts b/src/app/service-way/service-way.component.ts index 6c6af26..0ba4dcf 100644 --- a/src/app/service-way/service-way.component.ts +++ b/src/app/service-way/service-way.component.ts @@ -45,7 +45,7 @@ export class ServiceWayComponent implements OnDestroy, OnInit { this.uploadxService.ajax .request({ method: 'OPTIONS', url: this.options.endpoint as string }) .then(({ headers }) => { - if (hasher.isSupported && headers['tus-checksum-algorithm'].includes('sha1')) { + if (hasher.isSupported && headers['tus-checksum-algorithm']?.includes('sha1')) { this.uploadxService.options.prerequest = injectTusChecksumHeader; } }, console.error);