]> git.ipfire.org Git - thirdparty/jinja.git/commitdiff
file -> open for 3.x support. This fixes #152
authorArmin Ronacher <armin.ronacher@active-4.com>
Sat, 18 May 2013 10:44:49 +0000 (11:44 +0100)
committerArmin Ronacher <armin.ronacher@active-4.com>
Sat, 18 May 2013 10:44:49 +0000 (11:44 +0100)
jinja2/environment.py

index d19ae15c6678961cae0f5337cc0671cca626adaa..ed5977996cc2a32c2473087a8183140a0484fcd7 100644 (file)
@@ -1069,7 +1069,7 @@ class TemplateStream(six.Iterator):
         """
         close = False
         if isinstance(fp, six.string_types):
-            fp = file(fp, 'w')
+            fp = open(fp, 'w')
             close = True
         try:
             if encoding is not None: