mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-03-28 12:11:59 +01:00
feat(wm): report full errors in debug mode
This gives us a stack trace style error report in the log when in debug mode, which makes it much quicker to track down the origin of an error.
This commit is contained in:
@@ -44,7 +44,13 @@ pub fn listen_for_events(wm: Arc<Mutex<WindowManager>>) {
|
||||
if let Ok(event) = receiver.recv() {
|
||||
match wm.lock().process_event(event) {
|
||||
Ok(()) => {}
|
||||
Err(error) => tracing::error!("{}", error),
|
||||
Err(error) => {
|
||||
if cfg!(debug_assertions) {
|
||||
tracing::error!("{:?}", error)
|
||||
} else {
|
||||
tracing::error!("{}", error)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user