Fix moving when not in split-view mode

Don't insist on having a window (which caused an error), and don't
refuse to move in that case.
This commit is contained in:
djcb
2015-10-13 07:39:24 +03:00
parent ada193c8fd
commit a7d611c902
2 changed files with 4 additions and 5 deletions

View File

@ -850,7 +850,8 @@ this view."
(unless docid
(mu4e-error "message without docid: action is not possible."))
(with-current-buffer mu4e~view-headers-buffer
(select-window (get-buffer-window))
(when (get-buffer-window)
(select-window (get-buffer-window)))
(if (mu4e~headers-goto-docid docid)
,@body
(mu4e-error "cannot find message in headers buffer."))))))