From 5774fc8ac3f8f2fd398068bda22a9e214883a114 Mon Sep 17 00:00:00 2001 From: ChattyCha99 <52584342+ChattyCha99@users.noreply.github.com> Date: Fri, 1 Mar 2024 08:15:51 -0800 Subject: [PATCH] Revert "Option to only log publish messages to history" --- hookbox/channel.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/hookbox/channel.py b/hookbox/channel.py index ed05d05..3207a1d 100644 --- a/hookbox/channel.py +++ b/hookbox/channel.py @@ -17,7 +17,6 @@ class Channel(object): 'reflective': True, 'history': [], 'history_size': 0, - 'history_publish_only': False, 'moderated': True, 'moderated_publish': False, 'moderated_subscribe': False, @@ -228,7 +227,7 @@ def subscribe(self, user, conn=None, needs_auth=True): user.send_frame('SUBSCRIBE', frame) - if self.history_size and not self.history_publish_only: + if self.history_size: self.history.append(('SUBSCRIBE', {"user": user.get_name(), "datetime": _now })) self.prune_history() @@ -320,7 +319,7 @@ def unsubscribe(self, user, conn=None, needs_auth=True, force_auth=False): user.send_frame('UNSUBSCRIBE', frame) self.subscribers.remove(user) user.channel_unsubscribed(self) - if self.history_size and not self.history_publish_only: + if self.history_size: del frame['channel_name'] self.history.append(('UNSUBSCRIBE', frame)) self.prune_history()