code: def update(self, slug):
          '''
          Update the page.
          '''
  
          post_data = self.get_post_data()
  
          post_data['user_name'] = self.userinfo.user_name
  
          pageinfo = MWiki.get_by_uid(slug)
  
          cnt_old = tornado.escape.xhtml_unescape(pageinfo.cnt_md).strip()
          cnt_new = post_data['cnt_md'].strip()
          if cnt_old == cnt_new:
              pass
          else:
              MWikiHist.create_wiki_history(MWiki.get_by_uid(slug))
  
          MWiki.update(slug, post_data)
          tornado.ioloop.IOLoop.instance().add_callback(self.cele_gen_whoosh)
  
          self.redirect('/page/{0}'.format(post_data['slug'])f update(self, slug):
          '''
          Update the page.
          '''
  
          post_data = self.get_post_data()
  
          post_data['user_name'] = self.userinfo.user_name
  
          pageinfo = MWiki.get_by_uid(slug)
  
          cnt_old = tornado.escape.xhtml_unescape(pageinfo.cnt_md).strip()
          cnt_new = post_data['cnt_md'].strip()
          if cnt_old == cnt_new:
              pass
          else:
              MWikiHist.create_wiki_history(MWiki.get_by_uid(slug))
  
          MWiki.update(slug, post_data)
          tornado.ioloop.IOLoop.instance().add_callback(self.cele_gen_whoosh)
  
          self.redirect('/page/{0}'.format(post_data['slug']))
docs: Update the page.