1
0
Fork 0

feat(core): better log message formatting

This commit is contained in:
joostdecock 2023-06-11 09:30:53 +02:00
parent 8badef08f8
commit 88f74a4e5e
2 changed files with 5 additions and 5 deletions

View file

@ -46,7 +46,7 @@ export function Store(methods = []) {
for (const [path, method] of methods) {
if (avoid.indexOf(path) !== -1) {
this.log.warning(`You cannot overwrite store.${path}()`)
this.log.warning(`You cannot overwrite \`store.${path}()\``)
} else set(this, path, method)
}
@ -66,9 +66,9 @@ export function Store(methods = []) {
Store.prototype.extend = function (methods) {
for (const [path, method] of methods) {
if (avoid.indexOf(path) !== -1) {
this.log.warning(`You cannot overwrite store.${path}()`)
this.log.warning(`You cannot overwrite \`store.${path}()\``)
} else {
this.log.info(`Extending store with ${path}`)
this.log.info(`Extending store with \`${path}\``)
set(this, path, (...args) => method(this, ...args))
}
}