[Zope3-checkins] CVS: Zope3/src/zope/pagetemplate - pagetemplate.py:1.7

Barry Warsaw barry@zope.com
Tue, 15 Apr 2003 17:19:21 -0400


Update of /cvs-repository/Zope3/src/zope/pagetemplate
In directory cvs.zope.org:/tmp/cvs-serv26325/src/zope/pagetemplate

Modified Files:
	pagetemplate.py 
Log Message:
pt_render(): source is a boolean so use False here.

Also minor cosmetic change and whitespace normalization.


=== Zope3/src/zope/pagetemplate/pagetemplate.py 1.6 => 1.7 ===
--- Zope3/src/zope/pagetemplate/pagetemplate.py:1.6	Mon Apr 14 08:15:50 2003
+++ Zope3/src/zope/pagetemplate/pagetemplate.py	Tue Apr 15 17:19:20 2003
@@ -105,15 +105,15 @@
     def pt_getEngine(self):
         return Engine
 
-    def pt_render(self, namespace, source=0):
+    def pt_render(self, namespace, source=False):
         """Render this Page Template"""
         self._cook_check()
         __traceback_supplement__ = (PageTemplateTracebackSupplement,
                                     self, namespace)
         if self._v_errors:
             raise PTRuntimeError(str(self._v_errors))
-        output = StringIO(u'')
 
+        output = StringIO(u'')
         context = self.pt_getEngineContext(namespace)
         TALInterpreter(self._v_program, self._v_macros,
                        context, output, tal=not source, strictinsert=0)()
@@ -216,11 +216,11 @@
         if key == self.stringValue:
             return self.stringValue
         else:
-            return None 
+            return None
 
     def __nonzero__(self):
         return self.stringValue <> u''
-        
+
 
 
 class PTRuntimeError(RuntimeError):