From da37d893975d39786c9f4d1792bd9018bd101c5a Mon Sep 17 00:00:00 2001 From: Samir Kamal <1954121+skamril@users.noreply.github.com> Date: Mon, 23 Oct 2023 11:08:16 +0200 Subject: [PATCH] fix(results-ui): display results for a specific year --- .../App/Singlestudy/explore/Results/ResultDetails/utils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/src/components/App/Singlestudy/explore/Results/ResultDetails/utils.ts b/webapp/src/components/App/Singlestudy/explore/Results/ResultDetails/utils.ts index a2bcdd4af9..f140205498 100644 --- a/webapp/src/components/App/Singlestudy/explore/Results/ResultDetails/utils.ts +++ b/webapp/src/components/App/Singlestudy/explore/Results/ResultDetails/utils.ts @@ -36,7 +36,7 @@ export function createPath(params: Params): string { const { id, mode } = output; const isYearPeriod = year && year > 0; const periodFolder = isYearPeriod - ? `mc-ind/${Math.max(year, output.nbyears).toString().padStart(5, "0")}` + ? `mc-ind/${Math.min(year, output.nbyears).toString().padStart(5, "0")}` : "mc-all"; const isLink = "area1" in item; const itemType = isLink ? OutputItemType.Links : OutputItemType.Areas;