From e4926cb9e4a789a7f1644154bcbe95f80e2c3a3e Mon Sep 17 00:00:00 2001 From: Samuel Pastva Date: Thu, 31 Oct 2024 16:15:38 +0100 Subject: [PATCH] Send correct color count. --- src/main.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.rs b/src/main.rs index c891bbf..befb718 100644 --- a/src/main.rs +++ b/src/main.rs @@ -992,7 +992,7 @@ async fn get_control_stats() -> BackendResponse { let cmp = cmp.read().unwrap(); if let Some(computation) = &*cmp { let pstg = computation.graph.as_ref(); - let unit = pstg.mk_unit_colors(); + let unit = pstg.as_non_perturbable().mk_unit_colors(); if let Some(results) = computation.results.as_ref() { let mut minimal_perturbation: Option = None; let mut max_robustness: Option = None; @@ -1039,7 +1039,7 @@ async fn get_control_results() -> BackendResponse { let cmp = cmp.read().unwrap(); if let Some(computation) = &*cmp { let pstg = computation.graph.as_ref(); - let unit = pstg.mk_unit_colors(); + let unit = pstg.as_non_perturbable().mk_unit_colors(); if let Some(results) = computation.results.as_ref() { let mut response = JsonValue::new_array(); for (key, value) in results {