mirror of
https://github.com/9001/copyparty.git
synced 2025-08-17 00:52:16 -06:00
other linter nitpicks (not actually bugs)
This commit is contained in:
parent
f37187a041
commit
760ff2db72
|
@ -748,7 +748,7 @@ class HttpCli(object):
|
|||
or ("; Trident/" in self.ua and not k304)
|
||||
)
|
||||
|
||||
def _build_html_head(self, maybe_html: Any, kv: dict[str, Any]) -> bool:
|
||||
def _build_html_head(self, maybe_html: Any, kv: dict[str, Any]) -> None:
|
||||
html = str(maybe_html)
|
||||
is_jinja = html[:2] in "%@%"
|
||||
if is_jinja:
|
||||
|
@ -3075,6 +3075,7 @@ class HttpCli(object):
|
|||
logtail = ""
|
||||
|
||||
if ptop is not None:
|
||||
ap_data = "<%s>" % (req_path,)
|
||||
try:
|
||||
dp, fn = os.path.split(req_path)
|
||||
tnam = fn + ".PARTIAL"
|
||||
|
|
|
@ -361,7 +361,7 @@ class MDNS(MCast):
|
|||
except:
|
||||
pass
|
||||
|
||||
self.srv = {}
|
||||
self.srv.clear()
|
||||
|
||||
def eat(self, buf: bytes, addr: tuple[str, int], sck: socket.socket) -> None:
|
||||
cip = addr[0]
|
||||
|
|
|
@ -139,6 +139,9 @@ def au_unpk(
|
|||
zil = [x for x in zil if x.filename.lower().split(".")[-1] == au]
|
||||
fi = zf.open(zil[0])
|
||||
|
||||
else:
|
||||
raise Exception("unknown compression %s" % (pk,))
|
||||
|
||||
with os.fdopen(fd, "wb") as fo:
|
||||
while True:
|
||||
buf = fi.read(32768)
|
||||
|
|
|
@ -188,7 +188,7 @@ class SSDPd(MCast):
|
|||
except:
|
||||
pass
|
||||
|
||||
self.srv = {}
|
||||
self.srv.clear()
|
||||
|
||||
def eat(self, buf: bytes, addr: tuple[str, int]) -> None:
|
||||
cip = addr[0]
|
||||
|
|
Loading…
Reference in a new issue