irc: If there is no owner of a group in Telegram, in IRC show the service user as owner/founder
patch ca97990016d86bdb491bbead36be23125a3548a9
Author: E. Bosch <presidev@AT@gmail.com>
Date: Thu Mar 16 01:06:33 CET 2023
* irc: If there is no owner of a group in Telegram, in IRC show the service user as owner/founder
diff -rN -u old-irgramd/irc.py new-irgramd/irc.py
--- old-irgramd/irc.py 2024-10-23 02:38:07.482798089 +0200
+++ new-irgramd/irc.py 2024-10-23 02:38:07.482798089 +0200
@@ -579,7 +579,10 @@
chan = channel.lower()
topic = await self.tg.get_channel_topic(chan, entity_cache)
timestamp = await self.tg.get_channel_creation(chan, entity_cache)
- founder = list(self.irc_channels_founder[chan])[0]
+ if self.irc_channels_founder[chan]:
+ founder = list(self.irc_channels_founder[chan])[0]
+ else:
+ founder = self.service_user.irc_nick
await self.reply_code(user, 'RPL_TOPIC', (channel, topic))
await self.reply_code(user, 'RPL_TOPICWHOTIME', (channel, founder, timestamp))