patch 6c991a90a37dcc5a96906992b5c4df41e7f68991
Author: E. Bosch <presidev@AT@gmail.com>
Date: Thu Aug 29 23:06:59 CEST 2024
* Add trailing commas (and some spacing)
diff -rN -u old-irgramd/exclam.py new-irgramd/exclam.py
--- old-irgramd/exclam.py 2024-11-22 09:58:57.641220964 +0100
+++ new-irgramd/exclam.py 2024-11-22 09:58:57.641220964 +0100
@@ -59,7 +59,7 @@
(
' !re <compact_id> <message>',
'Reply with <message> to a message with <compact_id> on current',
- 'channel/chat.'
+ 'channel/chat.',
)
return reply
@@ -85,7 +85,7 @@
(
' !ed <compact_id> <new_message>',
'Edit a message with <compact_id> on current channel/chat,',
- '<new_message> replaces the current message.'
+ '<new_message> replaces the current message.',
)
return reply
@@ -165,7 +165,7 @@
' !upl <file name/URL> [<optional caption>]',
'Upload the file referenced by <file name/URL> to current',
'channel/chat, the file must be present in "upload"',
- 'irgramd local directory or be an external HTTP/HTTPS URL.'
+ 'irgramd local directory or be an external HTTP/HTTPS URL.',
)
return reply
@@ -185,6 +185,6 @@
'Reply with the upload of <file name/URL> to a message with',
'<compact_id> on current channel/chat. The file must be',
'present in "upload" irgramd local directory or be an external',
- 'HTTP/HTTPS URL.'
+ 'HTTP/HTTPS URL.',
)
return reply
diff -rN -u old-irgramd/service.py new-irgramd/service.py
--- old-irgramd/service.py 2024-11-22 09:58:57.641220964 +0100
+++ new-irgramd/service.py 2024-11-22 09:58:57.641220964 +0100
@@ -249,7 +249,7 @@
(
' mark_read <peer>',
'Mark all messages on <peer> (channel or user) as read, this also will',
- 'reset the number of mentions to you on <peer>.'
+ 'reset the number of mentions to you on <peer>.',
)
return reply
diff -rN -u old-irgramd/telegram.py new-irgramd/telegram.py
--- old-irgramd/telegram.py 2024-11-22 09:58:57.641220964 +0100
+++ new-irgramd/telegram.py 2024-11-22 09:58:57.645220958 +0100
@@ -29,7 +29,7 @@
TEST_IPS = { 1: '149.154.175.10',
2: '149.154.167.40',
- 3: '149.154.175.117'
+ 3: '149.154.175.117',
}
# Telegram
@@ -102,10 +102,10 @@
# Register Telegram callbacks
callbacks = (
(self.handle_telegram_message , telethon.events.NewMessage),
- (self.handle_raw, telethon.events.Raw),
+ (self.handle_raw , telethon.events.Raw),
(self.handle_telegram_chat_action, telethon.events.ChatAction),
(self.handle_telegram_deleted , telethon.events.MessageDeleted),
- (self.handle_telegram_edited, telethon.events.MessageEdited),
+ (self.handle_telegram_edited , telethon.events.MessageEdited),
)
for handler, event in callbacks:
self.telegram_client.add_event_handler(handler, event)
@@ -416,7 +416,7 @@
'rendered_text': proc_message,
'user': user,
'channel': chan,
- 'media': media
+ 'media': media,
}
def replace_mentions(self, text, me_nick='', received=True):