            (evernote-mode))
        (rename-buffer name t)
        (evernote-update-mode-line)
-       (set-buffer-modified-p nil)))))
+       (set-buffer-modified-p nil))
+     t)))
 
 
 (defun evernote-edit-tags ()

  (or (assq 'evernote-mode minor-mode-map-alist)
      (setq minor-mode-map-alist
            (cons (cons 'evernote-mode evernote-mode-map) minor-mode-map-alist)))
  (set-buffer-file-coding-system 'utf-8)
  (setq evernote-mode (not evernote-mode))
  (setq vc-mode
        (concat "[Tag:" (mapconcat #'identity evernote-note-tags ",") "] "
                "[Edit mode:" evernote-note-edit-mode "]"))
  (make-local-variable 'after-save-hook)
  (add-hook 'after-save-hook 'evernote-mode-after-save-hook)
  (run-hooks 'evernote-mode-hook))


(provide 'evernote-mode)

           (setq evernote-note-edit-mode
                 (evernote-read-edit-mode evernote-note-edit-mode))
           (evernote-update-mode-line)
           (set-buffer-modified-p t)))
     t)))


(defun evernote-rename-note ()
