wrap only if complex script

pull/5370/head
yann300 4 years ago
parent e6c63d495c
commit dc1afe2b7c
  1. 3
      apps/remix-ide/src/app/panels/terminal.js

@ -481,6 +481,7 @@ class Terminal extends Plugin {
return self._view.el
function wrapScript (script) {
if (script.startsWith('remix.')) return script
return `
try {
const ret = ${script};
@ -490,7 +491,7 @@ class Terminal extends Plugin {
console.log(ret)
}
} catch (e) {
console.log(error)
console.log(e.message)
}
`
}

Loading…
Cancel
Save