mirror of
https://github.com/transloadit/uppy.git
synced 2026-07-25 19:23:55 +00:00
companion: make logs to properly format objects
This commit is contained in:
parent
700b557c3b
commit
867f473e7e
1 changed files with 3 additions and 1 deletions
|
|
@ -45,5 +45,7 @@ exports.debug = (msg, tag) => {
|
|||
const log = (msg, tag, level) => {
|
||||
// @TODO add some colors based on log level
|
||||
const time = new Date().toISOString()
|
||||
console.log(`uppy: ${time} [${level}] ${tag || ''} ${msg}`)
|
||||
// exclude msg from template string so values such as error objects
|
||||
// can be well formatted
|
||||
console.log(`uppy: ${time} [${level}] ${tag || ''}`, msg)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue