changeset 2475:639a122cbc54

Merge devel.
author Karol 'grzywacz' Nowak <grzywacz@sul.uni.lodz.pl>
date Fri, 20 Jul 2007 13:27:41 +0200
parents 572f8ce1adff (current diff) d08d65a19718 (diff)
children 8a118b01df5a
files
diffstat 3 files changed, 4 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/xmlrpc/__init__.py	Fri Jul 20 13:18:46 2007 +0200
+++ b/MoinMoin/xmlrpc/__init__.py	Fri Jul 20 13:27:41 2007 +0200
@@ -958,6 +958,8 @@
         AttachFile._addLogEntry(self.request, 'ATTNEW', pagename, filename)
         return xmlrpclib.Boolean(1)
 
+    # XXX END WARNING XXX
+
 
     def xmlrpc_getBotTranslations(self):
         """ Return translations to be used by notification bot
@@ -967,8 +969,6 @@
         from MoinMoin.i18n import bot_translations
         return bot_translations(self.request)
 
-    # XXX END WARNING XXX
-
 
 class XmlRpc1(XmlRpcBase):
 
--- a/jabberbot/i18n.py	Fri Jul 20 13:18:46 2007 +0200
+++ b/jabberbot/i18n.py	Fri Jul 20 13:27:41 2007 +0200
@@ -22,8 +22,6 @@
     if not translations:
         init_i18n()
 
-    # get the matching entry in the mapping table
-    translated = original
     try:
         return translations[lang][original]
     except KeyError:
--- a/jabberbot/xmppbot.py	Fri Jul 20 13:18:46 2007 +0200
+++ b/jabberbot/xmppbot.py	Fri Jul 20 13:27:41 2007 +0200
@@ -204,6 +204,8 @@
         @param ignore_dnd: if command results in user interaction, should DnD be ignored?
 
         """
+        _ = self.getText(command.jid)
+        
         # Handle normal notifications
         if isinstance(command, cmd.NotificationCommand):
             for recipient in command.jids:
@@ -233,7 +235,6 @@
             self.remove_subscription(jid)
 
         elif isinstance(command, cmd.GetPage) or isinstance(command, cmd.GetPageHTML):
-            _ = self.getText(command.jid)
             msg = _(u"""Here's the page "%(pagename)s" that you've requested:\n\n%(data)s""")
 
             self.send_message(command.jid, msg % {
@@ -242,14 +243,12 @@
             })
 
         elif isinstance(command, cmd.GetPageList):
-            _ = self.getText(command.jid)
             msg = _("uThat's the list of pages accesible to you:\n\n%s")
             pagelist = u"\n".join(command.data)
 
             self.send_message(command.jid, msg % (pagelist, ))
 
         elif isinstance(command, cmd.GetPageInfo):
-            _ = self.getText(command.jid)
             msg = _("""Following detailed information on page "%(pagename)s" \
 is available::\n\n%(data)s""")