From a8b49f713b92afe0602db70e45862a9da477e390 Mon Sep 17 00:00:00 2001 From: Hykilpikonna Date: Sat, 1 Aug 2020 15:58:49 -0400 Subject: [PATCH] Revert "[O] Make gradedCourses a getter instead of a field" This reverts commit cc046010ff6e19fc28e98f5e88ac5525ffe117f4. --- src/components/app/app.ts | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/components/app/app.ts b/src/components/app/app.ts index 922c4d7..996db98 100644 --- a/src/components/app/app.ts +++ b/src/components/app/app.ts @@ -59,11 +59,6 @@ export default class App extends Vue // Is the login panel shown showLogin: boolean = !this.demoMode - get gradedCourses() - { - return this.courses.filter(course => course.isGraded); - } - /** * This is called when the instance is created. */ @@ -143,7 +138,14 @@ export default class App extends Vue }); // Wait for assignments to be ready. - pWaitFor(() => this.courses.every(c => c.rawAssignments != null)).then(this.checkGradingAlgorithms); + pWaitFor(() => this.courses.every(c => c.rawAssignments != null)).then(() => + { + // Filter courses + this.gradedCourses = this.courses.filter(c => c.isGraded); + + // Check grading algorithms + this.checkGradingAlgorithms(); + }); } /**