fix headers

This commit is contained in:
Antonio J. Delgado 2025-02-17 09:47:58 +02:00
parent 11a84f9180
commit 4bfe099883

View file

@ -75,10 +75,10 @@ class MastodonEmailBridge:
autoescape=select_autoescape()
)
self.translate_session = requests.Session()
headers = [
'accept: application/json',
'Content-Type: application/x-www-form-urlencoded',
]
headers = {
'accept': 'application/json',
'Content-Type': 'application/x-www-form-urlencoded',
}
self.translate_session.headers.update(headers)
self.session = requests.Session()
self.session.headers.update({'Authorization': f"Bearer {self.config['token']}"})