Skip to content

Commit

Permalink
Tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
Kikobeats committed Dec 24, 2017
1 parent 788c60a commit f131dfa
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/Format.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const isFalsy = value => [null, undefined, false].indexOf(value) !== -1
const isArray = arr => Array.isArray(arr)
const hasWhiteSpace = s => s.indexOf(' ') !== -1

const prettyObj = function (obj, color, opts) {
function prettyObj (obj, color, opts) {
const lineColor = getColor(CONST.LINE_COLOR)
const { offset, depth } = opts

Expand All @@ -39,7 +39,7 @@ const prettyObj = function (obj, color, opts) {
return fmtObj(obj, depth)
}

var serialize = function (obj, color, key) {
function serialize (obj, color, key) {
// symbols cannot be directly casted to strings
if (isSymbol(key)) key = key.toString()
if (isSymbol(obj)) obj = obj.toString()
Expand Down Expand Up @@ -89,8 +89,8 @@ var serialize = function (obj, color, key) {
return msg
}

const format = opts =>
function (messages) {
const createFormat = opts =>
function format (messages) {
const args = slice(arguments, 1)
const color = args.pop()

Expand Down Expand Up @@ -131,4 +131,4 @@ const format = opts =>
return serialize(messages, color)
}

module.exports = format
module.exports = createFormat

0 comments on commit f131dfa

Please sign in to comment.