pad: Display error name in the gritter box

This commit is contained in:
Richard Hansen 2021-06-03 15:01:23 -04:00
parent 63a5dc6599
commit b2e94685fb

View file

@ -311,6 +311,9 @@ padutils.setupGlobalExceptionHandler = () => {
} else {
throw new Error(`unknown event: ${e.toString()}`);
}
if (err.name != null && msg !== err.name && !msg.startsWith(`${err.name}: `)) {
msg = `${err.name}: ${msg}`;
}
const errorId = randomString(20);
let msgAlreadyVisible = false;