       Q(resource)
     else
       @bufferForPath(filePath).then (buffer) =>
-        @buildEditSessionForBuffer(buffer, options)
+        @buildEditorForBuffer(buffer, options)
 
   # Private: Only be used in specs
   openSync: (filePath, options={}) ->


  # Private:
  destroy: ->
    editor.destroy() for editor in @getEditSessions()
    buffer.release() for buffer in @getBuffers()
    @destroyRepo()


    for opener in @openers
      return resource if resource = opener(filePath, options)

    @buildEditorForBuffer(@bufferForPathSync(filePath), options)

  # Public: Retrieves all {Editor}s for all open files.
  #
  # Returns an {Array} of {Editor}s.
  getEditors: ->
    new Array(@editors...)

  # Public: Add the given {Editor}.
  addEditor: (editor) ->
    @editors.push editor
    @emit 'editor-created', editor

  # Public: Return and removes the given {Editor}.
  removeEditor: (editor) ->
    _.remove(@editors, editor)

  # Private: Retrieves all the {TextBuffer}s in the project; that is, the
