Skip to content
This repository has been archived by the owner on Aug 4, 2022. It is now read-only.

Commit

Permalink
Bug 1615898 [wpt PR 21822] - Iterating over dictionary's items with s…
Browse files Browse the repository at this point in the history
…ix library for PY2 & PY3 comp…, a=testonly

Automatic update from web-platform-tests
Iterating over dictionary's items with six library for PY2 & PY3 compatibility.

--

wpt-commits: ef72cc2212e324334032148aea9169edf2562ef5
wpt-pr: 21822
  • Loading branch information
ziransun authored and moz-wptsync-bot committed Feb 18, 2020
1 parent 3cfc648 commit 74d9a97
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

import webdriver

from six import iteritems


"""WebDriver wire protocol codecs."""

Expand Down Expand Up @@ -39,5 +41,5 @@ def object_hook(self, payload):
elif isinstance(payload, dict) and webdriver.Window.identifier in payload:
return webdriver.Window.from_json(payload, self.session)
elif isinstance(payload, dict):
return {k: self.object_hook(v) for k, v in payload.iteritems()}
return {k: self.object_hook(v) for k, v in iteritems(payload)}
return payload

0 comments on commit 74d9a97

Please sign in to comment.