From 61b3b9d7352f2b783de6e77eb0dd78977c11026c Mon Sep 17 00:00:00 2001 From: "Felix T.J. Dietrich" Date: Fri, 26 Jul 2024 13:58:12 +0200 Subject: [PATCH] Update playground/src/components/selectors/data_mode_select.tsx Co-authored-by: Dmytro Polityka <33299157+undernagruzez@users.noreply.github.com> --- playground/src/components/selectors/data_mode_select.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/playground/src/components/selectors/data_mode_select.tsx b/playground/src/components/selectors/data_mode_select.tsx index 95e6d66d..6d7f5f55 100644 --- a/playground/src/components/selectors/data_mode_select.tsx +++ b/playground/src/components/selectors/data_mode_select.tsx @@ -17,7 +17,8 @@ export default function DataModeSelect({ onChangeDataMode: (dataMode: DataMode) => void; }) { const queryClient = useQueryClient(); - const evaluationDataKey = dataMode.startsWith("evaluation-") ? dataMode.slice("evaluation-".length) : undefined; + const evaluationKey = "evaluation-"; + const evaluationDataKey = dataMode.startsWith(evaluationKey) ? dataMode.slice(evaluationKey.length) : undefined; const { data: exerciseData, error: exerciseError, isLoading: isLoadingExercises } = useExercises() const exerciseTypes = new Map();