diff --git a/src/error.rs b/src/error.rs index 7e1f23a..9a21b6d 100644 --- a/src/error.rs +++ b/src/error.rs @@ -53,7 +53,9 @@ pub struct ErrorPlugin; impl Plugin for ErrorPlugin { fn build(&self, app: &mut App) { - init_panic_handler(); + if !cfg!(debug_assertions) { + init_panic_handler(); + } if let Some(config) = app.world.get_resource::() { if let Some(dsn) = &config.sentry_dsn { let guard = sentry::init(dsn.clone());