cur_depth++;
if ((depth != INFINITE_DEPTH && cur_depth >= depth) ||
(is_repository_shallow() && !commit->parents &&
- (graft = lookup_commit_graft(get_object_hash(commit->object))) != NULL &&
+ (graft = lookup_commit_graft(commit->object.oid.hash)) != NULL &&
graft->nr_parent < 0)) {
commit_list_insert(commit, &result);
commit->object.flags |= shallow_flag;