Add code of conduct link button to help command

This commit is contained in:
2025-08-18 19:33:29 -03:00
parent 040b720755
commit 8ff7e3af02
+15
View File
@@ -26,6 +26,7 @@ impl Button<State> for HelpGoBackButton {
.component(HelpWebsiteLinkButton, 1)
.component(HelpSupportLinkButton, 1)
.component(HelpDonateLinkButton, 1)
.component(CodeOfConductLinkButton, 1)
.await
.inspect_err(|e| log::error!("An error occurred while attempting to edit the original message of an interaction. {e:?}"))
.map_err(
@@ -77,3 +78,17 @@ impl Button<State> for HelpDonateLinkButton {
Some("https://ko-fi.com/payphonedev")
}
}
#[derive(Debug)]
pub struct CodeOfConductLinkButton;
#[async_trait]
impl Button<State> for CodeOfConductLinkButton {
fn label(&self) -> Option<&'static str> {
Some("Code of Conduct")
}
fn url(&self) -> Option<&'static str> {
Some("https://payphone.lat/code-of-conduct")
}
}