sentry was never sending anything

This commit is contained in:
Tamo 2021-07-21 11:50:54 +02:00
parent 0136b02e5b
commit 5d4a0ac844
No known key found for this signature in database
GPG Key ID: 20CD8020AFA88D69
1 changed files with 6 additions and 6 deletions

View File

@ -49,12 +49,12 @@ async fn main() -> Result<(), MainError> {
release: sentry::release_name!(),
dsn: Some(SENTRY_DSN.parse()?),
before_send: Some(Arc::new(|event| {
event
.message
.as_ref()
.map(|msg| msg.to_lowercase().contains("no space left on device"))
.unwrap_or(false)
.then(|| event)
if matches!(event.message, Some(ref msg) if msg.to_lowercase().contains("no space left on device"))
{
None
} else {
Some(event)
}
})),
..Default::default()
});