From 98a4d85e2266bc4c5fded7c68c16982cc32d839e Mon Sep 17 00:00:00 2001 From: Steven Kessler Date: Wed, 1 Jan 2025 13:53:55 -0500 Subject: [PATCH] fix(clippy): fixed some clippy warnings --- src/migrators/pipenv.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/migrators/pipenv.rs b/src/migrators/pipenv.rs index 2ce1e0d..55106bd 100644 --- a/src/migrators/pipenv.rs +++ b/src/migrators/pipenv.rs @@ -127,8 +127,8 @@ impl PipenvMigrationSource { // Keep == intact, only clean single = if version.starts_with("==") { version.to_string() - } else if version.starts_with('=') { - version[1..].trim().to_string() + } else if let Some(stripped) = version.strip_prefix('=') { + stripped.trim().to_string() } else { version.to_string() }