From aecd794fca275b42e271b80236e95f0d288bd709 Mon Sep 17 00:00:00 2001 From: Jeff King Date: Fri, 14 Jun 2024 06:42:03 -0400 Subject: 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 Signed-off-by: Junio C Hamano --- builtin/ls-remote.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'builtin/ls-remote.c') 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]); -- cgit v1.3-5-g9baa