]> Devi Nivas Git - chevron.git/commitdiff
Fix flake8 error
authorNoah Morrison <noah@morrison.ph>
Wed, 3 Oct 2018 13:45:53 +0000 (09:45 -0400)
committerNoah Morrison <noah@morrison.ph>
Wed, 3 Oct 2018 13:45:53 +0000 (09:45 -0400)
chevron/renderer.py

index 9716ecb682e9831b2c567567afc1e625e5439087..a1dca72dc2b3566d0bfd38bb5b4acac07aa87fc8 100644 (file)
@@ -92,7 +92,8 @@ def _get_partial(name, partials_dict, partials_path, partials_ext):
         # Nope...
         try:
             # Maybe it's in the file system
-            path = partials_path + '/' + name + ('.' + partials_ext if partials_ext else '')
+            path_ext = ('.' + partials_ext if partials_ext else '')
+            path = partials_path + '/' + name + path_ext
             with io.open(path, 'r', encoding='utf-8') as partial:
                 return partial.read()