Fix console error messages

This commit is contained in:
Kurt Hutten
2021-09-09 18:36:11 +10:00
parent 5d128c6cbd
commit 2e2e7be633
5 changed files with 23 additions and 16 deletions

View File

@@ -43,13 +43,10 @@ export const render: DefaultKernelExport['render'] = async ({
}
const blob = await response.blob()
const text = await new Response(blob).text()
const { consoleMessage, customizerParams, type } = splitGziped(text)
const { consoleMessage } = splitGziped(text)
return createHealthyResponse({
type: type !== 'stl' ? 'png' : 'geometry',
data:
type !== 'stl'
? blob
: await stlToGeometry(window.URL.createObjectURL(blob)),
type: 'geometry',
data: await stlToGeometry(window.URL.createObjectURL(blob)),
consoleMessage,
date: new Date(),
})

View File

@@ -4,7 +4,7 @@ import { CadhubParams } from 'src/components/Customizer/customizerConverter'
export const lambdaBaseURL =
process.env.CAD_LAMBDA_BASE_URL ||
'https://2inlbple1b.execute-api.us-east-1.amazonaws.com/prod2'
'https://oxt2p7ddgj.execute-api.us-east-1.amazonaws.com/prod'
export const stlToGeometry = (url) =>
new Promise((resolve, reject) => {