aboutsummaryrefslogtreecommitdiffstats
path: root/odb.c
diff options
context:
space:
mode:
Diffstat (limited to 'odb.c')
-rw-r--r--odb.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/odb.c b/odb.c
index 240fc62ca2..d0ca299077 100644
--- a/odb.c
+++ b/odb.c
@@ -946,9 +946,10 @@ int has_object(struct repository *r, const struct object_id *oid,
return oid_object_info_extended(r, oid, NULL, object_info_flags) >= 0;
}
-void assert_oid_type(const struct object_id *oid, enum object_type expect)
+void odb_assert_oid_type(struct object_database *odb,
+ const struct object_id *oid, enum object_type expect)
{
- enum object_type type = oid_object_info(the_repository, oid, NULL);
+ enum object_type type = oid_object_info(odb->repo, oid, NULL);
if (type < 0)
die(_("%s is not a valid object"), oid_to_hex(oid));
if (type != expect)