patch 86ef89f9f9220ecde8477db2aa673f94f32656ab
Author: E. Bosch <presidev@AT@gmail.com>
Date: Sat Oct 26 20:43:28 CEST 2024
* telegram: Fix op and founder detection in channels
diff -rN -u old-irgramd/telegram.py new-irgramd/telegram.py
--- old-irgramd/telegram.py 2024-11-22 03:26:18.038583083 +0100
+++ new-irgramd/telegram.py 2024-11-22 03:26:18.042583077 +0100
@@ -181,10 +181,12 @@
if not user.is_self:
self.irc.irc_channels[chan].add(user_nick)
# Add admin users as ops in irc
- if isinstance(user.participant, tgty.ChatParticipantAdmin):
+ if isinstance(user.participant, tgty.ChatParticipantAdmin) or \
+ isinstance(user.participant, tgty.ChannelParticipantAdmin):
self.irc.irc_channels_ops[chan].add(user_nick)
# Add creator users as founders in irc
- elif isinstance(user.participant, tgty.ChatParticipantCreator):
+ elif isinstance(user.participant, tgty.ChatParticipantCreator) or \
+ isinstance(user.participant, tgty.ChannelParticipantCreator):
self.irc.irc_channels_founder[chan].add(user_nick)
def get_telegram_nick(self, user):