Skip to content

Commit 1cf7e92

Browse files
author
Patrick Gerard
committed
docs: add typerror exception to active_branch method
1 parent 6aa7fc5 commit 1cf7e92

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

git/repo/base.py

+2
Original file line numberDiff line numberDiff line change
@@ -858,6 +858,8 @@ def ignored(self, *paths: PathLike) -> List[str]:
858858
@property
859859
def active_branch(self) -> Head:
860860
"""The name of the currently active branch.
861+
862+
Raises: TypeError – If HEAD is detached
861863
:return: Head to the active branch"""
862864
# reveal_type(self.head.reference) # => Reference
863865
return self.head.reference

0 commit comments

Comments
 (0)