t7000-t7999: fix broken &&-chains
[gitweb.git] / fetch-pack.c
index a320ce9872b5e752aeb592a16cc9108ae87e9d71..cc7a42fee9fad161e37caacf87a15b2c1e33ec94 100644 (file)
@@ -657,11 +657,11 @@ static void filter_refs(struct fetch_pack_args *args,
                                }
                                i++;
                        }
-               }
 
-               if (!keep && args->fetch_all &&
-                   (!args->deepen || !starts_with(ref->name, "refs/tags/")))
-                       keep = 1;
+                       if (!keep && args->fetch_all &&
+                           (!args->deepen || !starts_with(ref->name, "refs/tags/")))
+                               keep = 1;
+               }
 
                if (keep) {
                        *newtail = ref;