Parcourir la source

properly handle missing parameters to \!exec-on-peer

Helge Jung il y a 9 ans
Parent
commit
606ccd1fe1
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      modules/ffpb.py

+ 1 - 1
modules/ffpb.py

@@ -813,7 +813,7 @@ def ffpb_nodemesh(bot, trigger):
 def ffpb_remoteexec(bot, trigger):
     """Remote execution on the given node"""
 
-    bot_params = trigger.group(2).split(' ', 1)
+    bot_params = trigger.group(2).split(' ', 1) if trigger.group(2) is not None else []
     if len(bot_params) != 2:
         bot.say('Wenn du nicht sagst wo mach ich remote execution bei dir!')
         bot.say('Tipp: !exec-on-peer <peer> <cmd>')