chore(tazjin/tgsa): Update quote footer text

Change-Id: I39ea4a40d9265d06193e3bddede157b10066da06
Reviewed-on: https://cl.tvl.fyi/c/depot/+/5477
Reviewed-by: tazjin <tazjin@tvl.su>
Autosubmit: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
This commit is contained in:
Vincent Ambo 2022-04-17 21:54:53 +02:00 committed by clbot
parent 2586abf6c2
commit 6c8841c176

View file

@ -9,6 +9,10 @@ struct TgLink {
}
impl TgLink {
fn human_friendly_url(&self) -> String {
format!("t.me/{}/{}", self.username, self.message_id)
}
fn to_url(&self) -> String {
format!("https://t.me/{}/{}?embed=1", self.username, self.message_id)
}
@ -153,8 +157,9 @@ fn to_bbcode(link: &TgLink, msg: &TgMessage) -> Result<String> {
}
out.push_str(&format!(
"\n\n[sub](via [url=\"{}\"]Telegram[/url])[/sub]",
"\n\n[sub](from [url=\"{}\"]{}[/url], via [url=\"https://tgsa.tazj.in\"]tgsa[/url])[/sub]",
link.to_url(),
link.human_friendly_url(),
));
out.push_str("\n[/quote]\n");