Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

Commit 3d2bcda

Browse files
committed
Fix wrong godoc on Tags() method.
Reword Tags() method documentation. Point to TagObjects() method to get all the tags on a repository. Signed-off-by: Antonio Jesus Navarro Perez <antnavper@gmail.com>
1 parent 9f00789 commit 3d2bcda

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

repository.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -845,8 +845,9 @@ func (r *Repository) Log(o *LogOptions) (object.CommitIter, error) {
845845
return nil, fmt.Errorf("invalid Order=%v", o.Order)
846846
}
847847

848-
// Tags returns all the References from Tags. This method returns all the tag
849-
// types, lightweight, and annotated ones.
848+
// Tags returns all the References from Tags. This method returns only lightweight
849+
// tags. Note that not all the tags are lightweight ones. To return annotated tags
850+
// too, you need to call TagObjects() method.
850851
func (r *Repository) Tags() (storer.ReferenceIter, error) {
851852
refIter, err := r.Storer.IterReferences()
852853
if err != nil {

0 commit comments

Comments
 (0)