From 80539743854260c34b24cf853c122794034c4d83 Mon Sep 17 00:00:00 2001 From: Phil Jackson Date: Thu, 1 Apr 2010 01:25:10 +0100 Subject: [PATCH] Revert "Fix `magit--branch-name-at-point'." This reverts commit e6e77c611f07f2ed593f27620fed54c63fa76df8. Reverting "Fix `magit--branch-name-at-point'." which I meant to put on another branch. --- magit.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/magit.el b/magit.el index faf8c33d..59430cd1 100644 --- a/magit.el +++ b/magit.el @@ -3574,7 +3574,10 @@ Will remove the 'remotes/' prefix if it exists." (defun magit--branch-name-at-point () "Get the branch name in the line at point." (let ((branch (magit--branch-name-from-line (thing-at-point 'line)))) - (or branch (error "No branch at point")))) + (if (or (= (point) (point-max)) + (not branch)) + (error "No branch found in current line")) + branch)) (defun magit-branches-window-checkout () "Check out the branch in the line at point."