Skip to content

Commit 470762c

Browse files
jxiaodevandreastt
authored andcommitted
py: migrate to base64.b64encode for Python 3.3 support
Also decodes string as UTF-8 afterwards. Fixes #8539 Signed-off-by: Andreas Tolfsen <ato@mozilla.com>
1 parent 829f21e commit 470762c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

py/selenium/webdriver/firefox/firefox_profile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ def encoded(self):
173173
filename = os.path.join(base, fyle)
174174
zipped.write(filename, filename[path_root:])
175175
zipped.close()
176-
return base64.encodestring(fp.getvalue())
176+
return base64.b64encode(fp.getvalue()).decode('UTF-8')
177177

178178
def set_proxy(self, proxy):
179179
import warnings

0 commit comments

Comments
 (0)