Skip to content

Commit c2dd96a

Browse files
committed
fix(multisubreddit): fix 500 on header spoofing
1 parent fb9dfdc commit c2dd96a

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

eddrit/utils/oauth.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,12 +91,10 @@ async def oauth_before_request(
9191

9292
# For multi subreddits, the user-agent doesn't work so tweak it
9393
if "+" in request.url.path:
94-
request.headers.encoding = "utf-8"
9594
request.headers["User-Agent"] = request.headers["User-Agent"].replace(
96-
"Android", "Andr\u200boid"
95+
"Android", "Amdroid"
9796
)
9897

99-
10098
def _get_login_headers_from_cache() -> dict[str, Any]:
10199
"""
102100
Get the login headers from cache

0 commit comments

Comments
 (0)