From 8f2a13cb266f19d9a30e2de21a7d8f0bd46eb167 Mon Sep 17 00:00:00 2001 From: Samuele Musiani Date: Fri, 7 Jun 2024 13:03:47 +0200 Subject: [PATCH] fix dash --- src/routes/dash/[course]/+page.svelte | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/routes/dash/[course]/+page.svelte b/src/routes/dash/[course]/+page.svelte index 2128446..f65dc9c 100644 --- a/src/routes/dash/[course]/+page.svelte +++ b/src/routes/dash/[course]/+page.svelte @@ -25,7 +25,8 @@ } function reorganizeTeachings(degree: Degree) { - if (degree.teachings != null) return { mandatory: [], electives: [] }; + if (degree.teachings != null && degree.teachings.length == 0) + return { mandatory: [], electives: [] }; const mandatory: TeachingsBatch[] = []; const electives: TeachingsBatch[] = [];