Commit 82443572 authored by Glenn Morris's avatar Glenn Morris
Browse files

Small recover-this-file improvement

* lisp/files.el (recover-this-file): Explicit error if not
visiting a file.  (Bug#23671)
parent 79abec2f
......@@ -5838,6 +5838,8 @@ an auto-save file."
(defun recover-this-file ()
"Recover the visited file--get contents from its last auto-save file."
(or buffer-file-name
(user-error "This buffer is not visiting a file"))
(recover-file buffer-file-name))
(defun recover-file (file)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment