From 899faef2284d7f80554cc5003517cce971446f27 Mon Sep 17 00:00:00 2001 From: igor <igor.markin@vereign.com> Date: Wed, 9 Jun 2021 14:45:17 +0300 Subject: [PATCH] Add build --- dist/services/CloudflareService.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/dist/services/CloudflareService.js b/dist/services/CloudflareService.js index 5c5fbb9..750a5fb 100644 --- a/dist/services/CloudflareService.js +++ b/dist/services/CloudflareService.js @@ -32,10 +32,7 @@ class CloudflareService { } fetchFile(fileName, bucket = this._defaultBucket) { return __awaiter(this, void 0, void 0, function* () { - // v?= is a dirty fix to prevent caching of the CORS error response in case file is missing. - // Because of browser caching CORS error in case of missing file, it's not possible to retrieve it when it's being uploaded. - // Dig into https://www.backblaze.com/b2/docs/cors_rules.html and fix - const response = yield axios_1.default(`${this._cdnUrl}/file/${bucket}/${fileName}?v=${Math.random()}`); + const response = yield axios_1.default(`${this._cdnUrl}/file/${bucket}/${fileName}`); const data = response.data; const uploadTime = response.headers["x-bz-upload-timestamp"] ? parseInt(response.headers["x-bz-upload-timestamp"]) -- GitLab