           detail: "File = #{languageBabelCfgFile}\n\n#{fileContent}"
       else
         # merge local config. config closest sourceFile wins
-        merge  jsonContent, localConfig
+        @merge  jsonContent, localConfig
         localConfig = jsonContent
     if fromDir isnt toDir
       # stop infinite recursion https://github.com/gandm/language-babel/issues/66

fs = require 'fs-plus'
path = require 'path'
pathIsInside = require 'path-is-inside'
merge = require('lodash/object/merge')

class Transpiler
  constructor: ->

      return @isBabelrcInPath path.dirname(fromDir)
    else return false

# simple merge of objects
  merge: (targetObj, sourceObj) ->
    for prop, val of sourceObj
      targetObj[prop] = val

module.exports = Transpiler
