mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-09-20 16:42:02 +00:00
Coloured warnings and errors under Node.js
This commit is contained in:
+1
-1
@@ -121,7 +121,7 @@ $tw.utils.error = function(err) {
|
||||
var errHeading = "Internal JavaScript Error",
|
||||
promptMsg = "Well, this is embarrassing. It is recommended that you restart TiddlyWiki by refreshing your browser";
|
||||
// Log the error to the console
|
||||
console.error(err);
|
||||
console.error($tw.node ? "\x1b[1;31m" + err + "\x1b[0m" : err);
|
||||
if($tw.browser && !$tw.node) {
|
||||
// Display an error message to the user
|
||||
var dm = $tw.utils.domMaker,
|
||||
|
||||
Reference in New Issue
Block a user