web/application.py
brancholdstable
changeset 7083 b8e35cde46e9
parent 6791 fe58b234f9c2
child 7348 dce4fa28ae49
equal deleted inserted replaced
7074:e4580e5f0703 7083:b8e35cde46e9
   232         self.session_manager.close_session(req.session)
   232         self.session_manager.close_session(req.session)
   233         sessioncookie = self.session_cookie(req)
   233         sessioncookie = self.session_cookie(req)
   234         req.remove_cookie(req.get_cookie(), sessioncookie)
   234         req.remove_cookie(req.get_cookie(), sessioncookie)
   235         raise LogOut(url=goto_url)
   235         raise LogOut(url=goto_url)
   236 
   236 
       
   237     # these are overridden by set_log_methods below
       
   238     # only defining here to prevent pylint from complaining
       
   239     info = warning = error = critical = exception = debug = lambda msg,*a,**kw: None
   237 
   240 
   238 class CubicWebPublisher(object):
   241 class CubicWebPublisher(object):
   239     """the publisher is a singleton hold by the web frontend, and is responsible
   242     """the publisher is a singleton hold by the web frontend, and is responsible
   240     to publish HTTP request.
   243     to publish HTTP request.
   241     """
   244     """
   456         template = req.form.get('__template', req.property_value('ui.main-template'))
   459         template = req.form.get('__template', req.property_value('ui.main-template'))
   457         if template not in self.vreg['views']:
   460         if template not in self.vreg['views']:
   458             template = 'main-template'
   461             template = 'main-template'
   459         return template
   462         return template
   460 
   463 
       
   464     # these are overridden by set_log_methods below
       
   465     # only defining here to prevent pylint from complaining
       
   466     info = warning = error = critical = exception = debug = lambda msg,*a,**kw: None
   461 
   467 
   462 set_log_methods(CubicWebPublisher, LOGGER)
   468 set_log_methods(CubicWebPublisher, LOGGER)
   463 set_log_methods(CookieSessionHandler, LOGGER)
   469 set_log_methods(CookieSessionHandler, LOGGER)