Skip to content

Commit

Permalink
Better support for Python 3 (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
abelpuentes authored and devsli committed Aug 31, 2017
1 parent b615417 commit 1d66e57
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion sofort/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from sofort.internals import Config, as_list
from sofort import model

from _version import __version__
from sofort._version import __version__

API_URL = 'https://api.sofort.com/api/xml'
TRANSACTION_ID = '-TRANSACTION-'
Expand Down
2 changes: 1 addition & 1 deletion sofort/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
def response(xmlstr):
result = xmltodict.parse(xmlstr)
# only one root element is allowed in XML
for root, value in result.iteritems():
for root, value in result.items():
if value is None:
return None
factory = factories[root]
Expand Down
2 changes: 1 addition & 1 deletion sofort/xml.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def multipay(config):
def transaction_request_by_params(params):
root = etree.Element('transaction_request')
root.set('version', '2')
for name, value in params.iteritems():
for name, value in params.items():
if name == 'transaction':
for transaction_id in value:
etree.SubElement(root, 'transaction').text = transaction_id
Expand Down

0 comments on commit 1d66e57

Please sign in to comment.