Skip to content

Commit ccd0025

Browse files
committed
Improve error logging
Signed-off-by: Johannes Schindelin <[email protected]>
1 parent 046d453 commit ccd0025

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

GitGitGadget/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,10 +131,10 @@ module.exports = async (context, req) => {
131131
};
132132
}
133133
} catch (e) {
134-
context.log('Caught exception ' + e);
134+
context.log('Caught exception ', e);
135135
context.res = {
136136
status: 500,
137-
body: 'Caught an error: ' + e,
137+
body: `Caught an error: ${e.message || JSON.stringify(e, null, 2)}`,
138138
};
139139
}
140140

0 commit comments

Comments
 (0)