From: Bernie Innocenti Date: Mon, 28 Jul 2008 06:03:29 +0000 (+0545) Subject: Rename PageFormatter::send_page() to PageFormatter::format() X-Git-Tag: v3.0~18 X-Git-Url: https://codewiz.org/gitweb?a=commitdiff_plain;h=666cc43781cace3f5a662a6403bee97c46a5c3a7;p=geekigeeki.git Rename PageFormatter::send_page() to PageFormatter::format() --- diff --git a/geekigeeki.py b/geekigeeki.py index b2e2895..0607006 100755 --- a/geekigeeki.py +++ b/geekigeeki.py @@ -233,11 +233,11 @@ def handle_edit(pagename): pg.save(form['file'].file.read()) else: pg.save(form['savetext'].value.replace('\r\n', '\n')) - pg.send_page() + pg.format() elif 'cancel' in form: pg.msg_text = 'Editing canceled' pg.msg_type = 'notice' - pg.send_page() + pg.format() else: # preview or edit text = None if 'preview' in form: @@ -463,7 +463,7 @@ class PageFormatter: + r"|(?P\[\[([^\s\|]+)(?:\s*\|\s*([^\]]+)|)\]\])" # Inline HTML - + r"|(?P<(/|)(div|span|iframe|form|input))" + + r"|(?P<(/|)(br|hr|div|form|iframe|input|span))" + r"|(?P[<>&])" # Auto links @@ -607,7 +607,7 @@ class Page: else: send_guru("Read access denied by ACLs", "notice") - def send_page(self): + def format(self): page_name = None if self.can_write(): page_name = self.page_name @@ -729,7 +729,7 @@ try: if file_re.match(query): if word_re.match(query): - Page(query).send_page() + Page(query).format() else: from mimetypes import MimeTypes type, encoding = MimeTypes().guess_type(query)