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>
This commit is contained in:
Jeff King
2024-06-14 06:42:03 -04:00
committed by Junio C Hamano
parent ffce821880
commit aecd794fca
6 changed files with 12 additions and 37 deletions

View File

@ -31,8 +31,6 @@ static int run_remote_archiver(int argc, const char **argv,
struct packet_reader reader;
_remote = remote_get(remote);
if (!_remote->url.nr)
die(_("git archive: Remote with no URL"));
transport = transport_get(_remote, _remote->url.v[0]);
transport_connect(transport, "git-upload-archive", exec, fd);