mirror of
https://gitlab.com/allianceauth/allianceauth.git
synced 2025-07-10 13:00:16 +02:00
headers for Discourse
This commit is contained in:
parent
2b09ca240d
commit
f70fbbdfee
@ -168,7 +168,7 @@ class DiscourseManager:
|
|||||||
for arg in kwargs:
|
for arg in kwargs:
|
||||||
if arg not in endpoint['args']['required'] and arg not in endpoint['args']['optional'] and not silent:
|
if arg not in endpoint['args']['required'] and arg not in endpoint['args']['optional'] and not silent:
|
||||||
logger.warn("Received unrecognized kwarg %s for endpoint %s" % (arg, endpoint))
|
logger.warn("Received unrecognized kwarg %s for endpoint %s" % (arg, endpoint))
|
||||||
r = getattr(requests, endpoint['method'])(settings.DISCOURSE_URL + endpoint['parsed_url'], params=params,
|
r = getattr(requests, endpoint['method'])(settings.DISCOURSE_URL + endpoint['parsed_url'], headers=params,
|
||||||
json=data)
|
json=data)
|
||||||
try:
|
try:
|
||||||
if 'errors' in r.json() and not silent:
|
if 'errors' in r.json() and not silent:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user