Merge bundle error message fix in
[gitweb.git] / builtin / fetch.c
index 65f5f9b72f92ec64ac5ad1ad264f78199337aba6..cfb43df4e843970a7ff93078ea1bcbbdb9985260 100644 (file)
@@ -300,11 +300,11 @@ static int update_local_ref(struct ref *ref,
                else {
                        msg = "storing head";
                        what = _("[new branch]");
-                       if ((recurse_submodules != RECURSE_SUBMODULES_OFF) &&
-                           (recurse_submodules != RECURSE_SUBMODULES_ON))
-                               check_for_new_submodule_commits(ref->new_sha1);
                }
 
+               if ((recurse_submodules != RECURSE_SUBMODULES_OFF) &&
+                   (recurse_submodules != RECURSE_SUBMODULES_ON))
+                       check_for_new_submodule_commits(ref->new_sha1);
                r = s_update_ref(msg, ref, 0);
                strbuf_addf(display, "%c %-*s %-*s -> %s%s",
                            r ? '!' : '*',