Add _debug facility to the Page class
[cascardo/ipsilon.git] / ipsilon / util / page.py
index 2cdca1c..56a6463 100755 (executable)
@@ -62,6 +62,10 @@ class Page(object):
         m.update(kwargs)
         return t.render(**m)
 
         m.update(kwargs)
         return t.render(**m)
 
+    def _debug(self, fact):
+        if cherrypy.config.get('debug', False):
+            cherrypy.log(fact)
+
     def default(self, *args, **kwargs):
         raise cherrypy.HTTPError(404)
 
     def default(self, *args, **kwargs):
         raise cherrypy.HTTPError(404)