RITlug / teleirc

Go implementation of a Telegram <=> IRC bridge for use with any IRC channel and Telegram group
https://docs.teleirc.com/
GNU General Public License v3.0
138 stars 46 forks source link

Add space after (edited) in edited Telegram messages #153

Closed Tjzabel closed 5 years ago

Tjzabel commented 5 years ago

This is a super pedantic issue, but when someone edits a message:

<T​jzabel> My message
<T​jzabel> (edited)My edited message

There should be a space between (edited) and the start of the message.

jwflory commented 5 years ago

Ahh, I noticed this too! I think it only happens when using a non-default edit message. In the case of the channels you and I are both in where I configured a non-default value, I did add the whitespace, but somehow it gets trimmed out.

A better implementation might be to hard-code the whitespace into TeleIRC, so an end-user doesn't have to remember to include it anyways for it to work.

Tjzabel commented 5 years ago

@jwflory ah, thanks for the clarification. I wasn't aware this was solely a non-default value issue.

jwflory commented 5 years ago

I would bet this could be fixed by adding whitespace here:

https://github.com/RITlug/teleirc/blob/36b10eeeb196a680f0fd0fa556c9176f889e40dd/lib/TelegramHandlers/TgEventListener.js#L83-L87

And removing whitespace here:

https://github.com/RITlug/teleirc/blob/36b10eeeb196a680f0fd0fa556c9176f889e40dd/config.js#L21

Tjzabel commented 5 years ago

That's most likely the fix :+1:

Tjzabel commented 5 years ago

Fixed in commit 3a401d4d1b39c36904287bc5b1ccb484b0ed2454