Radish alpha
h
Radicle Heartwood Protocol & Stack
Radicle
Git (anonymous pull)
Log in to clone via SSH
REVIEW: Simplify `fn parse_rid()`
✗ CI failure Erik Kundt committed 7 months ago
commit 4659ced42400cade9eaf9d86a3b1838e732e3e54
parent f0ecafa2aec8364cc31b428198a0e584a5f86be5
1 failed (1 total) View logs
1 file changed +1 -2
modified crates/radicle-cli/src/commands/clone/args.rs
@@ -20,8 +20,7 @@ from known seeds in the privacy set."#;

/// Parse an RID, optionally stripping "rad://" prefix.
fn parse_rid(value: &str) -> Result<RepoId, IdError> {
-
    use std::str::FromStr as _;
-
    RepoId::from_str(value.strip_prefix("rad://").unwrap_or(value))
+
    value.strip_prefix("rad://").unwrap_or(value).parse()
}

#[derive(Debug, Parser)]