aboutsummaryrefslogtreecommitdiff
path: root/repository/refs.go
diff options
context:
space:
mode:
authorGravatar Runxi Yu2026-03-24 06:10:36 +0000
committerGravatar Runxi Yu2026-03-24 06:10:36 +0000
commita454068d748a363833df3a2219ac278bcaf4c39b (patch)
tree43a8c0046d02b81688b068b1eda43913e6a81d20 /repository/refs.go
parentTODO: Remove that broken line (diff)
signatureNo signature
repository: Clarify ownership
Diffstat (limited to 'repository/refs.go')
-rw-r--r--repository/refs.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/repository/refs.go b/repository/refs.go
index a3e2cfb8..83afe047 100644
--- a/repository/refs.go
+++ b/repository/refs.go
@@ -4,6 +4,10 @@ import "codeberg.org/lindenii/furgit/refstore"
// Refs returns the configured ref store.
//
+// The returned store is owned by Repository and borrows repository-managed
+// resources. Callers must not close it directly, and it must not be used after
+// Close.
+//
//nolint:ireturn
func (repo *Repository) Refs() refstore.ReadWriteStore {
return repo.refs