From 14ad5916fca74a8144fe58e6e6a55201b6b123f2 Mon Sep 17 00:00:00 2001 From: ed Date: Sun, 19 Feb 2023 22:14:21 +0000 Subject: [PATCH] freebsd: fancy console listing for fetch --- copyparty/httpcli.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/copyparty/httpcli.py b/copyparty/httpcli.py index cb1884c4..3f062c0b 100644 --- a/copyparty/httpcli.py +++ b/copyparty/httpcli.py @@ -2833,7 +2833,7 @@ class HttpCli(object): } fmt = self.uparam.get("ls", "") - if not fmt and self.ua.startswith("curl/"): + if not fmt and (self.ua.startswith("curl/") or self.ua.startswith("fetch")): fmt = "v" if fmt in ["v", "t", "txt"]: @@ -3330,7 +3330,7 @@ class HttpCli(object): is_ls = "ls" in self.uparam is_js = self.args.force_js or self.cookies.get("js") == "y" - if not is_ls and self.ua.startswith("curl/"): + if not is_ls and (self.ua.startswith("curl/") or self.ua.startswith("fetch")): self.uparam["ls"] = "v" is_ls = True