From 27ca97999cc21e5279878432de5d9a931a30a68a Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Thu, 5 May 2022 15:18:37 -0400 Subject: [PATCH] test --- sopel_SpiceBot_Core_Prerun/__init__.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sopel_SpiceBot_Core_Prerun/__init__.py b/sopel_SpiceBot_Core_Prerun/__init__.py index d592ac9..28f3278 100644 --- a/sopel_SpiceBot_Core_Prerun/__init__.py +++ b/sopel_SpiceBot_Core_Prerun/__init__.py @@ -59,8 +59,7 @@ def prerun(): # If not piping the replies into pipe, let'sprint to IRC now if not comrun.is_pipe_command: - for say_message in comrun._say: - sb.osd(say_message) + comrun.osd(comrun._say) # Pipe text back to bot for next piped command else: for say_message in comrun._say: @@ -128,6 +127,11 @@ class ComRun(): def say(self, message): self._say.append(message) + def osd(self, messages, recipients=None, text_method='PRIVMSG', max_messages=-1): + if not recipients: + recipients = self.trigger.sender + sb.osd(messages, recipients, text_method, max_messages=-1) + @property def is_real_command(self): return sb.commands.is_real_command(self.command)