1
0
mirror of https://github.com/sasjs/server.git synced 2026-01-14 17:30:05 +00:00

fix(stp): return log+webout for debug on

This commit is contained in:
Saad Jutt
2022-04-02 07:06:09 +05:00
parent 7d5128c0d6
commit 3ff6f5e865
3 changed files with 7 additions and 8 deletions

View File

@@ -178,11 +178,10 @@ ${program}`
return { return {
httpHeaders, httpHeaders,
result: fileResponse result:
? webout isDebugOn(vars) || session.crashed
: isDebugOn(vars) || session.crashed ? `<html><body>${webout}<div style="text-align:left"><hr /><h2>SAS Log</h2><pre>${log}</pre></div></body></html>`
? `<html><body>${webout}<div style="text-align:left"><hr /><h2>SAS Log</h2><pre>${log}</pre></div></body></html>` : webout
: webout
} }
} }

View File

@@ -52,7 +52,7 @@ export const publishAppStream = async (
addEntryToFile addEntryToFile
) )
const sasJsPort = process.env.PORT ?? 5000 const sasJsPort = process.env.PORT || 5000
console.log( console.log(
'Serving Stream App: ', 'Serving Stream App: ',
`http://localhost:${sasJsPort}/AppStream/${streamServiceName}` `http://localhost:${sasJsPort}/AppStream/${streamServiceName}`

View File

@@ -4,8 +4,8 @@ import appPromise from './app'
import { getCertificates } from './utils' import { getCertificates } from './utils'
appPromise.then(async (app) => { appPromise.then(async (app) => {
const protocol = process.env.PROTOCOL ?? 'http' const protocol = process.env.PROTOCOL || 'http'
const sasJsPort = process.env.PORT ?? 5000 const sasJsPort = process.env.PORT || 5000
console.log('PROTOCOL: ', protocol) console.log('PROTOCOL: ', protocol)