refs.c: move for_each_remote_ref_submodule() to submodule.c

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Nguyễn Thái Ngọc Duy
2017-08-23 19:36:57 +07:00
committed by Junio C Hamano
parent 073cf63c52
commit 2e2d4040bd
3 changed files with 7 additions and 8 deletions

View File

@ -69,6 +69,13 @@ int is_staging_gitmodules_ok(const struct index_state *istate)
return 1;
}
static int for_each_remote_ref_submodule(const char *submodule,
each_ref_fn fn, void *cb_data)
{
return refs_for_each_remote_ref(get_submodule_ref_store(submodule),
fn, cb_data);
}
/*
* Try to update the "path" entry in the "submodule.<name>" section of the
* .gitmodules file. Return 0 only if a .gitmodules file was found, a section