From 6e29389b75869b12d27759ee15df3ce0882fc0a1 Mon Sep 17 00:00:00 2001 From: Darius Date: Thu, 12 Dec 2024 16:25:45 -0600 Subject: [PATCH] fix: remove timeout and convert payload to bytes properly --- extensions/warp-ipfs/src/shuttle/server.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/extensions/warp-ipfs/src/shuttle/server.rs b/extensions/warp-ipfs/src/shuttle/server.rs index 2f6767a74..68f83b135 100644 --- a/extensions/warp-ipfs/src/shuttle/server.rs +++ b/extensions/warp-ipfs/src/shuttle/server.rs @@ -407,7 +407,6 @@ impl ShuttleTask { let document: IdentityDocument = match ipfs .get_dag(path) - .timeout(Duration::from_secs(10)) .deserialized() .await { @@ -500,7 +499,7 @@ impl ShuttleTask { .build() .expect("Valid payload construction"); - let bytes = serde_json::to_vec(&payload).expect("Valid serialization"); + let bytes = payload.to_bytes().expect("valid deserialization"); _ = ipfs.pubsub_publish("/identity/announce/v0", bytes).await; @@ -779,7 +778,6 @@ impl ShuttleTask { let document: IdentityDocument = match ipfs .get_dag(path) - .timeout(Duration::from_secs(10)) .deserialized() .await { @@ -807,7 +805,7 @@ impl ShuttleTask { .build() .expect("Valid payload construction"); - let bytes = serde_json::to_vec(&payload).expect("Valid serialization"); + let bytes = payload.to_bytes().expect("valid deserialization"); _ = ipfs.pubsub_publish("/identity/announce/v0", bytes).await; }