Use a warning for logging.warn
This commit is contained in:
parent
6be5039163
commit
2992c411bb
1 changed files with 2 additions and 2 deletions
|
@ -61,8 +61,8 @@ export default class logging {
|
||||||
static warn(message, critical = false) {
|
static warn(message, critical = false) {
|
||||||
// Depackage the shortcut method of sending the error message, if it is.
|
// Depackage the shortcut method of sending the error message, if it is.
|
||||||
((typeof message).includes(`obj`))
|
((typeof message).includes(`obj`))
|
||||||
? console.error(`%c%s: %c%s`, `font-weight: bold; font-family: system-ui;`, message.name, `font-family: system-ui`, message.message)
|
? console.warn(`%c%s: %c%s`, `font-weight: bold; font-family: system-ui;`, message.name, `font-family: system-ui`, message.message)
|
||||||
: console.error(`%c%s`, `font-family: system-ui;`, message);
|
: console.warn(`%c%s`, `font-family: system-ui;`, message);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
(critical) ? alert(message) : M.toast({ text: message });
|
(critical) ? alert(message) : M.toast({ text: message });
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue