Skip to content
This repository has been archived by the owner on Apr 1, 2020. It is now read-only.

Commit

Permalink
Fixing console log
Browse files Browse the repository at this point in the history
  • Loading branch information
Stephen Cresswell committed Aug 10, 2017
1 parent 31b3f9d commit da592e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/components/logging/console.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ const chalk = require('chalk')
const hogan = require('hogan.js')
const merge = require('lodash.merge')
const has = require('lodash.has')
const pluck = require('lodash.pluck')
const omit = require('lodash.omit')

const response = hogan.compile('{{{displayTracer}}} {{{displayLevel}}} {{package.name}} {{{request.method}}} {{{response.statusCode}}} {{{request.url}}}')
const error = hogan.compile('{{{displayTracer}}} {{{displayLevel}}} {{package.name}} {{{message}}} {{{code}}}\n{{{error.stack}}} {{{details}}}')
Expand All @@ -23,7 +23,7 @@ module.exports = function() {
}

function onMessage(event) {
const details = pluck([], event)
const details = omit(event, ['message', 'level'])
const data = merge({}, event, {
displayTracer: has(event, 'tracer') ? event.tracer.substr(0, 6) : '------',
displayLevel: event.level.toUpperCase(),
Expand Down

0 comments on commit da592e9

Please sign in to comment.