diff roundup/cgi/engine_zopetal.py @ 4728:4caa6de726a5

templating: Rename 'extension' argument in Loader.load() to 'view' to avoid confusion with file extension, and because this is what this argument really does - specifies a different view for a class.
author anatoly techtonik <techtonik@gmail.com>
date Mon, 14 Jan 2013 00:13:58 +0300
parents 5033c2ad80a7
children d82ce9ad8044
line wrap: on
line diff
--- a/roundup/cgi/engine_zopetal.py	Sun Jan 13 22:39:46 2013 +0300
+++ b/roundup/cgi/engine_zopetal.py	Mon Jan 14 00:13:58 2013 +0300
@@ -21,16 +21,16 @@
     def __init__(self, dir):
         self.dir = dir
 
-    def load(self, name, extension=None):
+    def load(self, name, view=None):
         # default the name to "home"
         if name is None:
             name = 'home'
-        elif extension is None and '.' in name:
+        elif view is None and '.' in name:
             # split name
-            name, extension = name.split('.')
+            name, view = name.split('.')
 
         # find the source
-        src, filename = find_template(self.dir, name, extension)
+        src, filename = find_template(self.dir, name, view)
 
         # has it changed?
         try:

Roundup Issue Tracker: http://roundup-tracker.org/