@lucidtech/las-sdk-core
Advanced tools
Comparing version 13.0.0-beta.4 to 13.0.0-beta.5
@@ -662,3 +662,2 @@ /// <reference types="node" /> | ||
private makeAuthorizedFileServerRequest; | ||
private makeAuthorizedFileServerBodyRequest; | ||
private makeAuthorizedRequest; | ||
@@ -665,0 +664,0 @@ private makeAuthorizedBodyRequest; |
@@ -1088,4 +1088,4 @@ "use strict"; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
options.body = content; | ||
return this.makeAuthorizedFileServerBodyRequest(axios_1.default.put, fileUrl, options); | ||
options.data = content; | ||
return this.makeAuthorizedFileServerRequest(axios_1.default.put, fileUrl, options); | ||
}); | ||
@@ -1104,15 +1104,2 @@ } | ||
} | ||
makeAuthorizedFileServerBodyRequest(axiosFn, fileUrl, options = {}) { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const headers = yield this.getAuthorizationHeaders(); | ||
headers['Content-Type'] = 'application/octet-stream'; | ||
const { requestConfig } = options, body = __rest(options, ["requestConfig"]); | ||
let config = { headers }; | ||
if (requestConfig) { | ||
config = Object.assign(Object.assign({}, config), requestConfig); | ||
} | ||
const result = yield axiosFn(fileUrl, body, config); | ||
return result.data; | ||
}); | ||
} | ||
makeAuthorizedRequest(axiosFn, path, requestConfig = {}) { | ||
@@ -1119,0 +1106,0 @@ return __awaiter(this, void 0, void 0, function* () { |
{ | ||
"name": "@lucidtech/las-sdk-core", | ||
"version": "13.0.0-beta.4", | ||
"version": "13.0.0-beta.5", | ||
"author": "Lucidtech AS <hello@lucidtech.ai>", | ||
@@ -5,0 +5,0 @@ "maintainers": [ |
133519
2853