Commit 834bfa1
Ferass El Hafidi
src/bridge/MatrixHandler.ts: handle replying to self
When someone sent a message:
<f_[mtrx]> Hello?
And then replied to their own message:
<f_[mtrx]> > <@Funderscore:nova.astraltech.org> Hello?
Hi?
What would be sent on IRC would either be this:
<f_[mtrx]> Hello?
<f_[mtrx]> f_[mtrx]: Hi?
Or:
<f_[mtrx]> Hello?
-- a while later --
<f_[mtrx]> f_[mtrx]: "Hello?" <- Hi?
Both of which are confusing because usually nobody pings themself on
IRC.
This commit treats replies to self differently, and introduces a new
`selfReplyTemplate` config option, so that the reply gets bridged as:
<f_[mtrx]> <f_[mtrx]> Hello?
-- a while later --
<f_[mtrx]> Hi?
Or:
<f_[mtrx]> Hi?
Which is a bit more natural.
Signed-off-by: Ferass El Hafidi <[email protected]>1 parent 917f2c9 commit 834bfa1
File tree
3 files changed
+18
-2
lines changed- src/bridge
3 files changed
+18
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
602 | 602 | | |
603 | 603 | | |
604 | 604 | | |
| 605 | + | |
| 606 | + | |
605 | 607 | | |
606 | 608 | | |
607 | 609 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
171 | 171 | | |
172 | 172 | | |
173 | 173 | | |
| 174 | + | |
| 175 | + | |
174 | 176 | | |
175 | 177 | | |
176 | 178 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| 58 | + | |
| 59 | + | |
58 | 60 | | |
59 | 61 | | |
60 | 62 | | |
| |||
68 | 70 | | |
69 | 71 | | |
70 | 72 | | |
| 73 | + | |
71 | 74 | | |
72 | 75 | | |
73 | 76 | | |
| |||
1469 | 1472 | | |
1470 | 1473 | | |
1471 | 1474 | | |
1472 | | - | |
| 1475 | + | |
| 1476 | + | |
| 1477 | + | |
| 1478 | + | |
| 1479 | + | |
| 1480 | + | |
| 1481 | + | |
1473 | 1482 | | |
1474 | 1483 | | |
1475 | | - | |
| 1484 | + | |
| 1485 | + | |
| 1486 | + | |
| 1487 | + | |
1476 | 1488 | | |
1477 | 1489 | | |
1478 | 1490 | | |
| |||
0 commit comments