Skip to content

Commit

Permalink
Merge pull request #506 from simenheg/master
Browse files Browse the repository at this point in the history
Don't message "nil" when there is no error.
  • Loading branch information
jorgenschaefer committed Feb 23, 2015
2 parents 24f3d5b + 41485da commit 7cef60e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion elpy.el
Original file line number Diff line number Diff line change
Expand Up @@ -3315,7 +3315,9 @@ description."
(defun elpy-flymake-show-error ()
"Show the flymake error message at point."
(interactive)
(message "%s" (elpy-flymake-error-at-point)))
(let ((error-message (elpy-flymake-error-at-point)))
(when error-message
(message "%s" error-message))))

(defun elpy-flymake-error-at-point ()
"Return the flymake error at point, or nil if there is none."
Expand Down

0 comments on commit 7cef60e

Please sign in to comment.