提交 467b8fe1 编写于 作者: R René Scharfe 提交者: Junio C Hamano

submodule: remove redundant check for the_index.initialized

read_cache already performs the same check and returns immediately if
the cache has already been loaded.
Signed-off-by: NRené Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: NJunio C Hamano <gitster@pobox.com>
上级 26f8f32a
......@@ -603,9 +603,8 @@ int fetch_populated_submodules(const struct argv_array *options,
if (!work_tree)
goto out;
if (!the_index.initialized)
if (read_cache() < 0)
die("index file corrupt");
if (read_cache() < 0)
die("index file corrupt");
argv_array_push(&argv, "fetch");
for (i = 0; i < options->argc; i++)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册