We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6993765 commit 55d4f35Copy full SHA for 55d4f35
src/cli/self_update.rs
@@ -270,7 +270,7 @@ impl FromStr for SelfUpdateMode {
270
_ => Err(anyhow!(format!(
271
"unknown self update mode: '{}'; valid modes are {}",
272
mode,
273
- valid_self_update_modes(),
+ Self::modes().join(", "),
274
))),
275
}
276
@@ -1303,14 +1303,6 @@ pub(crate) fn cleanup_self_updater() -> Result<()> {
1303
Ok(())
1304
1305
1306
-pub(crate) fn valid_self_update_modes() -> String {
1307
- SelfUpdateMode::modes()
1308
- .iter()
1309
- .map(|s| format!("'{s}'"))
1310
- .collect::<Vec<_>>()
1311
- .join(", ")
1312
-}
1313
-
1314
#[cfg(test)]
1315
mod tests {
1316
use std::collections::HashMap;
0 commit comments