Suppress errors. Restyle
This commit is contained in:
parent
ea2cea573e
commit
3605d71b73
14
src/main.rs
14
src/main.rs
@ -176,6 +176,20 @@ async fn _main(tx: Sender<()>) -> Result<(), Box<dyn StdError + Send + Sync>> {
|
||||
allowed_mentions: None,
|
||||
command_check: Some(|ctx| Box::pin(all_checks(ctx))),
|
||||
event_handler: |ctx, event, _framework, data| Box::pin(listener(ctx, event, data)),
|
||||
on_error: |error| {
|
||||
Box::pin(async move {
|
||||
match error {
|
||||
poise::FrameworkError::CommandCheckFailed { .. } => {
|
||||
// suppress error
|
||||
}
|
||||
error => {
|
||||
if let Err(e) = poise::builtins::on_error(error).await {
|
||||
log::error!("Error while handling error: {}", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
..Default::default()
|
||||
};
|
||||
|
||||
|
@ -8,7 +8,7 @@ ExecStart=/usr/bin/reminder-rs
|
||||
WorkingDirectory=/etc/reminder-rs
|
||||
Restart=always
|
||||
RestartSec=4
|
||||
Environment="RUST_LOG=warn,reminder_rs=warn,postman=warn"
|
||||
Environment="reminder_rs=warn,postman=warn"
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
@ -373,10 +373,6 @@ input.default-width {
|
||||
}
|
||||
|
||||
.message-input:placeholder-shown {
|
||||
border-top: none;
|
||||
border-left: none;
|
||||
border-right: none;
|
||||
border-bottom-style: dashed;
|
||||
background-color: #40444b;
|
||||
color: #fff;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user