Skip to content

Commit

Permalink
fix(repository): fix async spawn formatting
Browse files Browse the repository at this point in the history
Corrects the formatting of an async block in the GitRepository implementation. Adds missing space in the tokio::spawn async block. Ensures consistent code formatting and readability.

BUG FIX: You appear to have made one or more backward-compatible bug fixes. According to Semantic Versioning (SemVer), this requires a patch version update. Please verify and update your version number accordingly.
  • Loading branch information
rrrodzilla committed Jun 29, 2024
1 parent bd521d5 commit 08df36b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/actors/repositories.rs
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,10 @@ impl GitRepository {
})
.expect("Failed to print diff");
let changes = String::from_utf8_lossy(&diff_text).to_string();

if changes.is_empty() {
error!("No diff for file: {}",&event.message.path.display().to_string());
return Context::noop();
}
let repository_event = BrokerRequest::new(DiffQueued::new(
changes,
target_file.clone(),
Expand Down Expand Up @@ -240,7 +243,7 @@ impl GitRepository {
let path = file.clone();
let trace_id = id.clone();
let repository_event = FileChangeDetected::new(file.into());
tokio::spawn(async move{
tokio::spawn(async move {
outbound_envelope.reply_async(repository_event, None).await;
});
trace!(
Expand Down

0 comments on commit 08df36b

Please sign in to comment.