         if t = atom.config.get('haskell-ghc-mod.onSelectionShow')
           @["#{t}Tooltip"] editor, crange
 
-  checkCommand: ({target}) =>
-    editor = target.getModel()
+  checkCommand: ({currentTarget}) =>
+    editor = currentTarget.getModel()
     @process.doCheckBuffer(editor.getBuffer()).then (res) =>
       @setMessages res, ['error', 'warning']
 
-  lintCommand: ({target}) =>
-    editor = target.getModel()
+  lintCommand: ({currentTarget}) =>
+    editor = currentTarget.getModel()
     @process.doLintBuffer(editor.getBuffer()).then (res) =>
       @setMessages res, ['lint']
 
   tooltipCommand: (tooltipfun) =>
-    ({target, detail}) =>
+    ({currentTarget, detail}) =>
       @upi.showTooltip
-        editor: target.getModel()
+        editor: currentTarget.getModel()
         detail: detail
         tooltip: (crange) ->
-          tooltipfun target.getModel(), crange
-
-  insertTypeCommand: ({target, detail}) =>
+          tooltipfun currentTarget.getModel(), crange
+
+  insertTypeCommand: ({currentTarget, detail}) =>
     Util = require './util'
-    editor = target.getModel()
+    editor = currentTarget.getModel()
     @upi.withEventRange {editor, detail}, ({crange, pos}) =>
       @process.getTypeInBuffer(editor.getBuffer(), crange)
       .then (o) ->

          editor.setTextInBufferRange o.range,
            "(#{editor.getTextInBufferRange(o.range)} :: #{type})"

  caseSplitCommand: ({target, detail}) =>
    editor = target.getModel()
    @upi.withEventRange {editor, detail}, ({crange}) =>
      @process.doCaseSplit(editor.getBuffer(), crange)
      .then (res) ->
        res.forEach ({range, replacement}) ->
          editor.setTextInBufferRange(range, replacement)

  sigFillCommand: ({target, detail}) =>
    editor = target.getModel()
    @upi.withEventRange {editor, detail}, ({crange}) =>
      @process.doSigFill(editor.getBuffer(), crange)
      .then (res) ->

            for row in newrange.getRows().slice(1)
              editor.setIndentationForBufferRow row, indent

  goToDeclCommand: ({currentTarget, detail}) =>
    editor = currentTarget.getModel()
    @upi.withEventRange {editor, detail}, ({crange}) =>
      @process.getInfoInBuffer(editor, crange)
      .then ({range, info}) =>
