def update(self): if not cherrypy.session.get('auth', False): raise cherrypy.HTTPRedirect('/') else: return vars(cherrypy.session['user'])