From 91291e09e8fd3395f8a1265c9af2bd22eff46993 Mon Sep 17 00:00:00 2001 From: Jeff Dickey <216188+jdx@users.noreply.github.com> Date: Wed, 1 May 2024 17:56:22 -0500 Subject: [PATCH] fix: prevent crashing if "latest" is not a symlink Fixes #2011 --- src/forge/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/forge/mod.rs b/src/forge/mod.rs index bee30db99..05d39e8e0 100644 --- a/src/forge/mod.rs +++ b/src/forge/mod.rs @@ -230,7 +230,7 @@ pub trait Forge: Debug + Send + Sync { } None => { let installed_symlink = self.fa().installs_path.join("latest"); - if installed_symlink.exists() { + if installed_symlink.is_symlink() { let target = installed_symlink.read_link()?; let version = target .file_name()