     scanRange = new Range(startPairPosition.traverse([0, 1]), @editor.buffer.getEndPosition())
     endPairPosition = null
     unpairedCount = 0
-    @editor.scanInBufferRange pairRegexes[startPair], scanRange, (result) ->
+    @editor.scanInBufferRange @pairRegexes[startPair], scanRange, (result) ->
       switch result.match[0]
         when startPair
           unpairedCount++

  destroy: =>
    @subscriptions.dispose()

  subscribeToCursor: ->
    cursor = @editor.getLastCursor()
    return unless cursor?


  findAnyStartPair: (cursorPosition) ->
    scanRange = new Range([0, 0], cursorPosition)
    startPair = _.escapeRegExp(_.keys(@startPairMatches).join(''))
    endPair = _.escapeRegExp(_.keys(@endPairMatches).join(''))
    combinedRegExp = new RegExp("[#{startPair}#{endPair}]", 'g')
    startPairRegExp = new RegExp("[#{startPair}]", 'g')
    endPairRegExp = new RegExp("[#{endPair}]", 'g')
