       @activateNormalMode()
 
   destroy: ->
-    unless @destroyed
-      @destroyed = true
-      @emitter.emit 'did-destroy'
-      @subscriptions.dispose()
-      if @editor.isAlive()
-        @deactivateInsertMode()
-        @editorElement.component?.setInputEnabled(true)
-        @editorElement.classList.remove("vim-mode")
-        @editorElement.classList.remove("normal-mode")
-      @editor = null
-      @editorElement = null
+    return if @destroyed
+    @destroyed = true
+    @emitter.emit 'did-destroy'
+    @subscriptions.dispose()
+    if @editor.isAlive()
+      @deactivateInsertMode()
+      @editorElement.component?.setInputEnabled(true)
+      @editorElement.classList.remove("vim-mode")
+      @editorElement.classList.remove("normal-mode")
+    @editor = null
+    @editorElement = null
 
   # Private: Creates the plugin's bindings
   #

  # the given object.
  registerOperationCommands: (operationCommands) ->
    commands = {}
    for commandName, operationFn of operationCommands
      do (operationFn) =>
        commands[commandName] = (event) => @enqueueOperations(operationFn(event))
    @registerCommands(commands)

  # Private: Push the given operations onto the operation stack, then process

  getRegister: (name) ->
    if name is '"'
      name = settings.defaultRegister()

    switch name
      when '*', '+'
        text = atom.clipboard.read()
        type = Utils.copyType(text)
        {text, type}
      when '%'
        text = @editor.getURI()
        type = Utils.copyType(text)
        {text, type}
      when '_' # Blackhole always returns nothing
        text = ''
        type = Utils.copyType(text)
        {text, type}
      else
        @globalVimState.registers[name.toLowerCase()]

  # Private: Fetches the value of a given mark.
  #
