From 63d72fbdefa46f00951f7154a236a3c600ad9f07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20H=C3=B6rist?= Date: Thu, 5 Sep 2019 21:13:00 +0200 Subject: HTTPAuth: Parse attrs correctly Fixes #84 --- nbxmpp/modules/http_auth.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'nbxmpp/modules') diff --git a/nbxmpp/modules/http_auth.py b/nbxmpp/modules/http_auth.py index df8ac1f..fb78c46 100644 --- a/nbxmpp/modules/http_auth.py +++ b/nbxmpp/modules/http_auth.py @@ -45,7 +45,10 @@ class HTTPAuth: if confirm is None: return - http_auth = confirm.getAttrs().copy() - http_auth['body'] = stanza.getTagData('body') - properties.http_auth = HTTPAuthData(**http_auth) - log.info('Found data: %s', http_auth) + attrs = confirm.getAttrs() + body = stanza.getTagData('body') + id_ = attrs.get('id') + method = attrs.get('method') + url = attrs.get('url') + properties.http_auth = HTTPAuthData(id_, method, url, body) + log.info('HTTPAuth received: %s %s %s %s', id_, method, url, body) -- cgit v1.2.3