[cpif] r372 - trunk/frontend-web

svn at argo.es svn at argo.es
Fri Sep 21 04:04:08 CEST 2007


Author: jcea
Date: Fri Sep 21 04:04:02 2007
New Revision: 372

Log:
El nuevo skin tenia problemas con los metatags (subforos) vacios.

Como efecto colateral, quito un invariante de un bucle, ganando
rendimiento.



Modified:
   trunk/frontend-web/skins.py

Modified: trunk/frontend-web/skins.py
==============================================================================
--- trunk/frontend-web/skins.py	(original)
+++ trunk/frontend-web/skins.py	Fri Sep 21 04:04:02 2007
@@ -232,6 +232,7 @@
 
   def list_threads(self):
     """Format the thread list"""
+    aux=""  # If there are not threads
     threads = ["stickies", "threads"]
     metatag = self._dict.get("metatag",None)
     tz=self._dict["tz"]
@@ -288,11 +289,11 @@
                 "read only": read_only,
                 "sticky": sticky,
                 }
-          # The monitoring of the metatag:
-          mon = available_skins[self._skin]['metatag_unmon'] if self._dict["monitor"] else available_skins[self._skin]['metatag_mon'] 
-          mon = mon % { "metatag_num": metatag }
-          self._dict["mon"] = mon
-          self.set_text(aux)
+    # The monitoring of the metatag:
+    mon = available_skins[self._skin]['metatag_unmon'] if self._dict["monitor"] else available_skins[self._skin]['metatag_mon'] 
+    mon = mon % { "metatag_num": metatag }
+    self._dict["mon"] = mon
+    self.set_text(aux)
 
   def _header(self):
     return available_skins[self._skin]['header'] % self._dict
@@ -336,7 +337,7 @@
       aux = available_skins[self._skin]['generic']
       self.set_text(self._dict.get('generic_message',None))
 
-    ret = self._dict # Pillamos el diccionario a deolver
+    ret = self._dict # Pillamos el diccionario a devolver
     ret['body'] = "\r\n".join(self._text) # Aniado el texto
     return aux % ret
 



More information about the cpif mailing list