Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
project: Check path extension first, then worktree's (#29671)
Oleksiy Syvokon632f08d2a3b7
diff --git a/crates/project/src/image_store.rs b/crates/project/src/image_store.rsindex 3d3e93fc669..dd8db2c675f 100644--- a/crates/project/src/image_store.rs+++ b/crates/project/src/image_store.rs@@ -217,9 +217,9 @@ pub fn is_image_file(project: &Entity<Project>, path: &ProjectPath, cx: &App) ->.worktree_for_id(path.worktree_id, cx)?.read(cx).abs_path();- worktree_abs_path+ path.path.extension()- .or_else(|| path.path.extension())+ .or_else(|| worktree_abs_path.extension()).and_then(OsStr::to_str).map(str::to_lowercase)});