commit | 58d458dd62cf61374f621322f984cf149b324e56 | [log] [tgz] |
---|---|---|
author | Armin Ronacher <armin.ronacher@active-4.com> | Sat May 18 11:46:35 2013 +0100 |
committer | Armin Ronacher <armin.ronacher@active-4.com> | Sat May 18 11:46:35 2013 +0100 |
tree | 5e9125db300d9573c0ef17bf62561027cec27bff | |
parent | e6c0630249c052f953686a7c8e155e5c5b4b075c [diff] |
Make dump() work Python 3.3
diff --git a/jinja2/environment.py b/jinja2/environment.py index ed59779..58573a2 100644 --- a/jinja2/environment.py +++ b/jinja2/environment.py
@@ -1069,7 +1069,7 @@ """ close = False if isinstance(fp, six.string_types): - fp = open(fp, 'w') + fp = open(fp, encoding is None and 'w' or 'wb') close = True try: if encoding is not None: