Skip to content

Commit e596eaf

Browse files
committed
Try debug
1 parent 4cf0f2a commit e596eaf

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

src/epsilon/server/instance_provider.rs

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,6 @@ pub async fn get(template: &str, instance_provider: &State<Arc<InstanceProvider>
194194

195195
#[rocket::get("/get_all")]
196196
pub async fn get_all(instance_provider: &State<Arc<InstanceProvider>>) -> String {
197-
198197
info!("Fetching all instances");
199198

200199
let instances = instance_provider
@@ -206,10 +205,16 @@ pub async fn get_all(instance_provider: &State<Arc<InstanceProvider>>) -> String
206205

207206
info!("Fetched {} instances", instances.len());
208207

209-
let mut json_array: Vec<InstanceJson> = Vec::with_capacity(instances.len());
208+
let mut json_array: Vec<InstanceJson> = Vec::new();
210209

211210
for instance in instances {
212-
json_array.push(instance.to_json().await);
211+
let json = instance.to_json().await;
212+
213+
info!("JSON");
214+
215+
json_array.push(json);
216+
217+
info!("PUSH")
213218
}
214219

215220
info!("Converted {} instances to json", json_array.len());

0 commit comments

Comments
 (0)