Suppress errors. Restyle
This commit is contained in:
		
							
								
								
									
										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, |         allowed_mentions: None, | ||||||
|         command_check: Some(|ctx| Box::pin(all_checks(ctx))), |         command_check: Some(|ctx| Box::pin(all_checks(ctx))), | ||||||
|         event_handler: |ctx, event, _framework, data| Box::pin(listener(ctx, event, data)), |         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() |         ..Default::default() | ||||||
|     }; |     }; | ||||||
|  |  | ||||||
|   | |||||||
| @@ -8,7 +8,7 @@ ExecStart=/usr/bin/reminder-rs | |||||||
| WorkingDirectory=/etc/reminder-rs | WorkingDirectory=/etc/reminder-rs | ||||||
| Restart=always | Restart=always | ||||||
| RestartSec=4 | RestartSec=4 | ||||||
| Environment="RUST_LOG=warn,reminder_rs=warn,postman=warn" | Environment="reminder_rs=warn,postman=warn" | ||||||
|  |  | ||||||
| [Install] | [Install] | ||||||
| WantedBy=multi-user.target | WantedBy=multi-user.target | ||||||
|   | |||||||
| @@ -373,10 +373,6 @@ input.default-width { | |||||||
| } | } | ||||||
|  |  | ||||||
| .message-input:placeholder-shown { | .message-input:placeholder-shown { | ||||||
|     border-top: none; |  | ||||||
|     border-left: none; |  | ||||||
|     border-right: none; |  | ||||||
|     border-bottom-style: dashed; |  | ||||||
|     background-color: #40444b; |     background-color: #40444b; | ||||||
|     color: #fff; |     color: #fff; | ||||||
| } | } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user