refs: tidy up and adjust visibility of the `ref_update` flags
[gitweb.git] / notes.c
diff --git a/notes.c b/notes.c
index 5c62862574399acb486530d3fab5a7f659eb7c2f..d273822b2859b9877b1814a49d4f2dce9fad1d8b 100644 (file)
--- a/notes.c
+++ b/notes.c
@@ -1027,7 +1027,7 @@ void init_notes(struct notes_tree *t, const char *notes_ref,
        if (flags & NOTES_INIT_EMPTY || !notes_ref ||
            get_oid_treeish(notes_ref, &object_oid))
                return;
-       if (flags & NOTES_INIT_WRITABLE && read_ref(notes_ref, object_oid.hash))
+       if (flags & NOTES_INIT_WRITABLE && read_ref(notes_ref, &object_oid))
                die("Cannot use notes ref %s", notes_ref);
        if (get_tree_entry(object_oid.hash, "", oid.hash, &mode))
                die("Failed to read notes tree referenced by %s (%s)",