mirror of
https://github.com/9001/copyparty.git
synced 2025-11-03 05:23:31 +00:00
u2c: fix delete-url (closes #948);
u2c would produce an URL which triggered a windows-only sanchk serverside, rejecting the delete-request
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
#!/usr/bin/env python3
|
||||
from __future__ import print_function, unicode_literals
|
||||
|
||||
S_VERSION = "2.13"
|
||||
S_BUILD_DT = "2025-09-05"
|
||||
S_VERSION = "2.14"
|
||||
S_BUILD_DT = "2025-10-24"
|
||||
|
||||
"""
|
||||
u2c.py: upload to copyparty
|
||||
@@ -1225,9 +1225,7 @@ class Ctl(object):
|
||||
while req:
|
||||
print("DELETING ~%s#%s" % (srd, len(req)))
|
||||
body = json.dumps(req).encode("utf-8")
|
||||
sc, txt = web.req(
|
||||
"POST", self.ar.url + "?delete", {}, body, MJ
|
||||
)
|
||||
sc, txt = web.req("POST", "/?delete", {}, body, MJ)
|
||||
if sc == 413 and "json 2big" in txt:
|
||||
print(" (delete request too big; slicing...)")
|
||||
req = req[: len(req) // 2]
|
||||
|
||||
Reference in New Issue
Block a user