From a0593e3aa9b19b9ca3c3881cbe0d9d207fe46d2c Mon Sep 17 00:00:00 2001 From: DanConwayDev Date: Tue, 26 Nov 2024 07:48:30 +0000 Subject: refactor: err msgs 'cannot' > 'failed to' in nearly all cases 'cannot' was used when an action was tried and failed. 'failed to' is strictly better because: * just because the action didn't work that time doesnt mean it cannot work * it is better at drawing the users attention to a problem --- src/bin/git_remote_nostr/fetch.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/bin/git_remote_nostr/fetch.rs') diff --git a/src/bin/git_remote_nostr/fetch.rs b/src/bin/git_remote_nostr/fetch.rs index a972a2f..90387f3 100644 --- a/src/bin/git_remote_nostr/fetch.rs +++ b/src/bin/git_remote_nostr/fetch.rs @@ -110,7 +110,7 @@ pub fn make_commits_for_proposal( let commit_id = git_repo .create_commit_from_patch(patch, Some(tip_commit_id.clone())) .context(format!( - "cannot create commit for patch {}", + "failed to create commit for patch {}", nip19::Nip19Event { event_id: patch.id, author: Some(patch.pubkey), @@ -146,7 +146,7 @@ async fn fetch_proposals( { if let Err(error) = make_commits_for_proposal(git_repo, repo_ref, patches) { term.write_line( - format!("WARNING: cannot create branch for {refstr}, error: {error}",) + format!("WARNING: failed to create branch for {refstr}, error: {error}",) .as_str(), )?; break; -- cgit v1.2.3