@sasjs/adapter 3.8.2 → 3.8.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +2 -2
- package/node/index.js +2 -2
- package/package.json +1 -1
- package/src/utils/parseViyaDebugResponse.ts +7 -2
package/package.json
CHANGED
|
@@ -16,10 +16,15 @@ export const parseSasViyaDebugResponse = async (
|
|
|
16
16
|
requestClient: RequestClient,
|
|
17
17
|
serverUrl: string
|
|
18
18
|
) => {
|
|
19
|
+
// On viya 3.5, iframe is like <iframe style="width: 99%; height: 500px" src="..."></iframe>
|
|
20
|
+
// On viya 4, iframe is like <iframe style="width: 99%; height: 500px; background-color:Canvas;" src=...></iframe>
|
|
21
|
+
|
|
19
22
|
const iframeStart = response.split(
|
|
20
|
-
|
|
23
|
+
/<iframe style="width: 99%; height: 500px" src="|<iframe style="width: 99%; height: 500px; background-color:Canvas;" src=/
|
|
21
24
|
)[1]
|
|
22
|
-
const jsonUrl = iframeStart
|
|
25
|
+
const jsonUrl = iframeStart
|
|
26
|
+
? iframeStart.split(/"><\/iframe>|><\/iframe>/)[0]
|
|
27
|
+
: null
|
|
23
28
|
if (!jsonUrl) {
|
|
24
29
|
throw new Error('Unable to find webout file URL.')
|
|
25
30
|
}
|