aboutsummaryrefslogtreecommitdiffstats
path: root/builtin/ls-remote.c
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2024-06-14 06:42:03 -0400
committerJunio C Hamano <gitster@pobox.com>2024-06-14 09:34:39 -0700
commitaecd794fca275b42e271b80236e95f0d288bd709 (patch)
tree109cc0ab15551b45c7a98780c9d0b1da8db99572 /builtin/ls-remote.c
parentffce821880408768be21e08a02fecd686e780d01 (diff)
downloadgit-aecd794fca275b42e271b80236e95f0d288bd709.tar.gz
remote: drop checks for zero-url case
Now that the previous commit removed the possibility that a "struct remote" will ever have zero url fields, we can drop a number of redundant checks and untriggerable code paths. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/ls-remote.c')
-rw-r--r--builtin/ls-remote.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/builtin/ls-remote.c b/builtin/ls-remote.c
index 4c04dbbf19..8f3a64d838 100644
--- a/builtin/ls-remote.c
+++ b/builtin/ls-remote.c
@@ -109,8 +109,6 @@ int cmd_ls_remote(int argc, const char **argv, const char *prefix)
die("bad repository '%s'", dest);
die("No remote configured to list refs from.");
}
- if (!remote->url.nr)
- die("remote %s has no configured URL", dest);
if (get_url) {
printf("%s\n", remote->url.v[0]);