chore: Trim the strings in repo announce command

Signed-off-by: Awiteb <a@4rs.nl>
This commit is contained in:
Awiteb
2025-05-06 11:30:13 +00:00
parent 9b4dfb9374
commit a56acf5752
3 changed files with 10 additions and 4 deletions

View File

@@ -72,6 +72,7 @@ impl EventBuilder {
maintainers: Vec<PublicKey>,
labels: Vec<String>,
) -> N34Result<EventBuilder> {
let repo_id = repo_id.trim();
if repo_id.is_empty() || repo_id != repo_id.to_case(Case::Kebab) {
return Err(N34Error::InvalidRepoId);
}