diff options
author | Tyler Schicke <tyler_schicke@brown.edu> | 2019-05-28 13:46:47 -0400 |
---|---|---|
committer | Tyler Schicke <tyler_schicke@brown.edu> | 2019-05-28 13:46:47 -0400 |
commit | ca95adb9a7b213455ea919b18c70eef0f2334bd9 (patch) | |
tree | 814c0d72a50d5647a99cf90fdad90700f715f84a /src/debug | |
parent | f7ae243462a819c69ee4ba9d828b69b3685a0e13 (diff) |
Made REPL formatting better
Diffstat (limited to 'src/debug')
-rw-r--r-- | src/debug/Repl.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/debug/Repl.tsx b/src/debug/Repl.tsx index ef00ed466..01acb0e76 100644 --- a/src/debug/Repl.tsx +++ b/src/debug/Repl.tsx @@ -24,7 +24,7 @@ class Repl extends React.Component { if (result.success) { this.executedCommands.push({ command: this.text, result: result.result }); } else { - this.executedCommands.push({ command: this.text, result: result.error }); + this.executedCommands.push({ command: this.text, result: result.error.message || result.error }); } } this.text = ""; @@ -37,7 +37,7 @@ class Repl extends React.Component { return ( <div style={{ marginTop: "5px" }}> <p>{command.command}</p> - <p>{JSON.stringify(command.result)}</p> + <pre>{JSON.stringify(command.result, null, 2)}</pre> </div> ); }); |