mirror of
https://git.pleroma.social/pleroma/relay.git
synced 2024-11-23 15:08:00 +00:00
Fix algorithm reference
This commit is contained in:
parent
6a0c1fe726
commit
acd38ce9f7
|
@ -3,7 +3,7 @@ import traceback
|
|||
|
||||
from aiohttp import ClientSession, ClientTimeout, TCPConnector
|
||||
from aiohttp.client_exceptions import ClientConnectorError, ServerTimeoutError
|
||||
from aputils import Nodeinfo, WellKnownNodeinfo
|
||||
from aputils import Nodeinfo, WellKnownNodeinfo, AlgorithmType
|
||||
from datetime import datetime
|
||||
from cachetools import LRUCache
|
||||
from json.decoder import JSONDecodeError
|
||||
|
@ -141,10 +141,10 @@ class HttpClient:
|
|||
|
||||
# Using the old algo by default is probably a better idea right now
|
||||
if (instance and instance.get('software') in {'mastodon'}) or (software and software in {'mastodon'}):
|
||||
algorithm = 'hs2019'
|
||||
algorithm = AlgorithmType.HS2019
|
||||
|
||||
else:
|
||||
algorithm = 'original'
|
||||
algorithm = AlgorithmType.ORIGINAL
|
||||
|
||||
headers = {'Content-Type': 'application/activity+json'}
|
||||
headers.update(self.database.signer.sign_headers(
|
||||
|
|
Loading…
Reference in a new issue