Skip to content

Commit

Permalink
Merge pull request #41 from stakpak/fix/infinite-loop
Browse files Browse the repository at this point in the history
revert
  • Loading branch information
ahmedhesham6 authored Feb 24, 2025
2 parents db7f7b9 + a8f4ea1 commit ea07f28
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/commands/agent/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,10 @@ impl AgentCommands {
get_or_create_session(&client, agent_id, checkpoint_id, Some(input.clone()))
.await?;

// TODO: Better way to allow sync for specific agents
if matches!(agent_id, AgentID::KevinV1) && session.flow_ref.is_some() {
if let Some(flow_ref) = &session.flow_ref {
let config_clone = config.clone();
let client_clone = Client::new(&config_clone).map_err(|e| e.to_string())?;
let flow_ref = session.flow_ref.clone().unwrap();
let flow_ref = flow_ref.clone();
tokio::spawn(async move {
flow::sync(&config_clone, &client_clone, &flow_ref, None).await
});
Expand Down

0 comments on commit ea07f28

Please sign in to comment.