Don't fail in magit-describe-item when item is nil.
This commit is contained in:
parent
864248a582
commit
7ad6d4dd55
1 changed files with 7 additions and 6 deletions
13
magit.el
13
magit.el
|
@ -1305,11 +1305,12 @@ Please see the manual for a complete description of Magit.
|
||||||
(defun magit-describe-item ()
|
(defun magit-describe-item ()
|
||||||
(interactive)
|
(interactive)
|
||||||
(let ((item (magit-get-item)))
|
(let ((item (magit-get-item)))
|
||||||
(message "Item: %s %s-%s %S"
|
(if item
|
||||||
(magit-item-type item)
|
(message "Item: %s %s-%s %S"
|
||||||
(magit-item-beginning item)
|
(magit-item-type item)
|
||||||
(magit-item-ending item)
|
(magit-item-beginning item)
|
||||||
(magit-item-info item))))
|
(magit-item-ending item)
|
||||||
|
(magit-item-info item))
|
||||||
|
(message "No item here"))))
|
||||||
|
|
||||||
(provide 'magit)
|
(provide 'magit)
|
||||||
|
|
Loading…
Reference in a new issue