Compare commits

..

4 Commits

Author SHA1 Message Date
e6c0511b33 Fix page rendering when a leftbox is rendered
All checks were successful
Create Docker Image / Build Docker Image (x86_64) (push) Successful in 50s
Create Docker Image / Build Docker Image (arm64) (push) Successful in -16h54m16s
Create Docker Image / Final Docker Image Manifest (push) Successful in 12s
2024-09-09 08:23:40 +10:00
7f95305d75 Fixes for DE-LIST notifications 2024-09-09 08:23:40 +10:00
9d7455233b Improvements for finding intransit netmails to upstream and peer hubs 2024-09-09 08:23:40 +10:00
c70222fef8 When posting to matrix, encode in triple backticks to create a mono-spaced message 2024-09-09 08:23:40 +10:00

View File

@ -63,8 +63,9 @@ class Echomail extends Matrix
->withQueryParameters(['user_id'=>$user]) ->withQueryParameters(['user_id'=>$user])
->post(sprintf('https://%s/_matrix/client/v3/rooms/%s/send/m.room.message',config('matrix.server'),$room),[ ->post(sprintf('https://%s/_matrix/client/v3/rooms/%s/send/m.room.message',config('matrix.server'),$room),[
'msgtype'=>'m.text', 'msgtype'=>'m.text',
'format'=>'org.matrix.custom.html',
'body'=>mb_convert_encoding(str_replace("\r","\n",$this->o->msg),'UTF-8','IBM850'), 'body'=>mb_convert_encoding(str_replace("\r","\n",$this->o->msg),'UTF-8','IBM850'),
'formatted_body'=>sprintf("```\n%s\n```",mb_convert_encoding(str_replace("\r","\n",$this->o->msg),'UTF-8','IBM850')), 'formatted_body'=>sprintf("<pre>\n%s\n</pre>",mb_convert_encoding(str_replace("\r","\n",$this->o->msg),'UTF-8','IBM850')),
]); ]);
switch ($msg->status()) { switch ($msg->status()) {