mirror of
https://github.com/sasjs/adapter.git
synced 2026-01-06 20:10:05 +00:00
Merge pull request #505 from sasjs/fileuploader-quick-fix
fix(fileUploader): parsing debug response for SASVIYA
This commit is contained in:
@@ -61,15 +61,14 @@ export class FileUploader {
|
|||||||
'Content-Type': 'text/plain'
|
'Content-Type': 'text/plain'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// currently only web approach is supported for file upload
|
||||||
|
// therefore log is part of response with debug enabled and must be parsed
|
||||||
return this.requestClient
|
return this.requestClient
|
||||||
.post(uploadUrl, formData, undefined, 'application/json', headers)
|
.post(uploadUrl, formData, undefined, 'application/json', headers)
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
// for web approach on Viya
|
|
||||||
if (
|
if (
|
||||||
this.sasjsConfig.debug &&
|
this.sasjsConfig.serverType === ServerType.SasViya &&
|
||||||
(this.sasjsConfig.useComputeApi === null ||
|
this.sasjsConfig.debug
|
||||||
this.sasjsConfig.useComputeApi === undefined) &&
|
|
||||||
this.sasjsConfig.serverType === ServerType.SasViya
|
|
||||||
) {
|
) {
|
||||||
const jsonResponse = await parseSasViyaDebugResponse(
|
const jsonResponse = await parseSasViyaDebugResponse(
|
||||||
res.result as string,
|
res.result as string,
|
||||||
|
|||||||
Reference in New Issue
Block a user