This commit is contained in:
Martin McKeaveney 2020-05-18 15:46:38 +01:00
parent c054b3404e
commit 7f0f8f2d9f
4 changed files with 12 additions and 9 deletions

View File

@ -10,6 +10,7 @@
"build": {
"appId": "com.budibase.builder",
"productName": "Budibase Builder",
"afterSign": "electron-builder-notarize",
"mac": {
"category": "public.app-category.developer-tools",
"hardenedRuntime": true
@ -29,7 +30,7 @@
"budi": "node ../cli/bin/budi",
"dev:builder": "nodemon ../cli/bin/budi run",
"electron": "electron src/electron.js",
"build:electron": "electron-builder",
"build:electron": "electron-builder --dir",
"publish:electron": "electron-builder -mwl --publish always",
"postinstall": "electron-builder install-app-deps",
"lint": "eslint --fix src/"

View File

@ -48,7 +48,7 @@ router.use(async (ctx, next) => {
try {
await next()
} catch (err) {
ctx.log.error(err);
ctx.log.error(err)
ctx.status = err.status || err.statusCode || 500
ctx.body = {
message: err.message,

View File

@ -10,12 +10,14 @@ const app = new Koa()
// set up top level koa middleware
app.use(koaBody({ multipart: true }))
app.use(logger({
prettyPrint: {
levelFirst: true
},
level: process.env.NODE_ENV === "jest" ? "silent" : "info"
}))
app.use(
logger({
prettyPrint: {
levelFirst: true,
},
level: process.env.NODE_ENV === "jest" ? "silent" : "info",
})
)
// api routes
app.use(api.routes())