changeset 2223:eec3c7b6a686

make sure pi['language'] is set, even for xslt pages
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Thu, 21 Jun 2007 09:30:35 +0200
parents 90484c86443a
children 4ca25b36adb0
files MoinMoin/Page.py
diffstat 1 files changed, 4 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/Page.py	Sat May 26 19:56:30 2007 +0200
+++ b/MoinMoin/Page.py	Thu Jun 21 09:30:35 2007 +0200
@@ -888,6 +888,9 @@
         request = self.request
         pi = {} # we collect the processing instructions here
 
+        # default language from cfg
+        pi['language'] = self.cfg.language_default or "en"
+
         body = self.body
         # TODO: remove this hack once we have separate metadata and can use mimetype there
         if body.startswith('<?xml'): # check for XML content
@@ -902,11 +905,9 @@
         # default is wiki markup
         pi['format'] = self.cfg.default_markup or "wiki"
         pi['formatargs'] = ''
-        # default language from cfg
-        pi['language'] = self.cfg.language_default or "en"
         pi['lines'] = len(meta)
         acl = []
-        
+
         for verb, args in meta:
             if verb == "format": # markup format
                 format, formatargs = (args + ' ').split(' ', 1)