Skip to content

Commit

Permalink
perf test
Browse files Browse the repository at this point in the history
  • Loading branch information
adbar committed Apr 25, 2024
1 parent 9b83c83 commit 6ac97e4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions courlan/clean.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def scrub_url(url: str) -> str:
# strip space in input string
url = "".join(url.split()).strip(
"\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
"\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f \r\n"
"\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
)

# <![CDATA[http://www.urbanlife.de/item/260-bmw-i8-hybrid-revolution-unter-den-sportwagen.html]]>
Expand Down Expand Up @@ -112,10 +112,10 @@ def clean_query(
querystring: str, strict: bool = False, language: Optional[str] = None
) -> str:
"Strip unwanted query elements"
qdict = parse_qs(querystring)
if not qdict:
if not querystring:
return ""

qdict = parse_qs(querystring)
newqdict = {}

for qelem in sorted(qdict):
Expand Down

0 comments on commit 6ac97e4

Please sign in to comment.