From 62c92141e39f958d5946193593e2fa4818819366 Mon Sep 17 00:00:00 2001 From: itsjunetime Date: Sun, 8 Jun 2025 21:13:39 -0600 Subject: [PATCH] Make it work correctly with ghostty image eviction too --- src/main.rs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/main.rs b/src/main.rs index 61db985..9e9fb37 100644 --- a/src/main.rs +++ b/src/main.rs @@ -427,12 +427,10 @@ async fn enter_redraw_loop( if let Err((to_replace, err_desc, enum_err)) = maybe_err { match enum_err { - // This is the error that kitty provides us when it deletes an image due to - // memory constraints, so if we get it, we just fix it by re-rendering and - // don't display it to the user - TransmitError::Terminal(TerminalError::NoEntity(e)) - if e.contains("refers to non-existent image") => - (), + // This is the error that kitty & ghostty provide us when they delete an + // image due to memory constraints, so if we get it, we just fix it by + // re-rendering so it don't display it to the user + TransmitError::Terminal(TerminalError::NoEntity(_)) => (), _ => tui.set_msg(MessageSetting::Some(BottomMessage::Error(format!( "{err_desc}: {enum_err}" ))))