diff options
| author | olive <olive@olive.ooo> | 2026-09-17 20:29:09 +0100 |
|---|---|---|
| committer | olive <olive@olive.ooo> | 2026-09-17 20:29:09 +0100 |
| commit | 9157750d04dfb2863bc5822b908336e663b141b1 (patch) | |
| tree | 3ec8ac81aef2ea1e67db38d6c2b013ee8dddab33 /quaddle/pylon.lua | |
| parent | 87ed4adab569504e4ce053f8288a84404f63c8dc (diff) | |
Use shortname config rather than hard-coding [x] and so on.
Pylons may also make their own choce in how they format the short-name
when sending out (or do it differently altogether), rather than it being
baked-in by the receiving pylon.
Diffstat (limited to 'quaddle/pylon.lua')
| -rw-r--r-- | quaddle/pylon.lua | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/quaddle/pylon.lua b/quaddle/pylon.lua index d176260..2213a76 100644 --- a/quaddle/pylon.lua +++ b/quaddle/pylon.lua @@ -81,9 +81,10 @@ end function Quaddle.handle_message(self, msg) self.log:proto('<',msg.channel_id,msg.author.username,msg.content) if msg.author.id ~= self.bot_user.id then - self.wilson:deliver(Channel(self, msg.channel), { + self.wilson:deliver({ + source_channel = Channel(self, msg.channel), body = msg.content, - sender = '[q]' .. msg.author.name, + sender = msg.author.name, }) end end @@ -93,7 +94,7 @@ function Quaddle.sending(self) self.log:proto('>', dest_channel, message.sender, message.body) self:_req('channels/'..dest_channel.descriptor..'/messages', { - content = message.sender..": "..message.body, + content = "["..message.source_channel.pylon.shortname.."] "..message.sender..": "..message.body, }) end end |
