changeset 170:7dfda4ff75b7

Fixed missing-</a> bug hopefully. imported from: moin--main--1.5--patch-172
author Alexander Schremmer <alex@alexanderweb.de.tla>
date Sun, 30 Oct 2005 22:25:59 +0000
parents 826780dc1607
children 11740ebb136c
files MoinMoin/formatter/text_html.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/formatter/text_html.py	Sun Oct 30 21:46:20 2005 +0000
+++ b/MoinMoin/formatter/text_html.py	Sun Oct 30 22:25:59 2005 +0000
@@ -219,18 +219,18 @@
             See wikiutil.link_tag() for possible keyword parameters.
         """
         apply(FormatterBase.pagelink, (self, on, pagename, page), kw)
+        self.pagelink_preclosed = False
         if page is None:
             page = Page(self.request, pagename, formatter=self);
         import sys; sys.stderr.write("DEBUG - pagelink: page is %r\n" % (page))    
         if self.request.user.show_nonexist_qm and on and not page.exists():
+            import sys; sys.stderr.write("DEBUG - Calling 2x link_to(**%r)\n" % (kw))
             self.pagelink_preclosed = True
-            import sys; sys.stderr.write("DEBUG - Calling 2x link_to(**%r)\n" % (kw))
             return (page.link_to(self.request, on=1, **kw) +
                     self.text("?") +
                     page.link_to(self.request, on=0, **kw))
         elif not on and self.pagelink_preclosed:
             import sys; sys.stderr.write("DEBUG - pagelink: was preclosed\n" )
-            self.pagelink_preclosed = False
             return ""
         else:
             import sys; sys.stderr.write("DEBUG - pagelink: calling link_to\n" )