From 259d4c3474d236aa15e1ae0103a6d936102b536c Mon Sep 17 00:00:00 2001 From: Hykilpikonna Date: Sun, 12 Apr 2020 16:21:50 -0400 Subject: [PATCH] [O] Replace more in course names --- src/logic/course-info.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/logic/course-info.ts b/src/logic/course-info.ts index 24926ff..8ff8351 100644 --- a/src/logic/course-info.ts +++ b/src/logic/course-info.ts @@ -26,9 +26,12 @@ export default class CourseInfo this.level = json.level this.courseIds = json.courseIds.split('|').map((id: string) => +id); - this.uniqueName = this.name.replace(/( A| CP| H)$/g, '') this.courseCount = this.courseIds.length; this.gradeLevels = []; + this.uniqueName = this.name + .replace(/( Semester| Full Year|)/g, '') + .replace(/( Accelerated| Honors| College Prep|)/g, '') + .replace(/( A| Acc| CP| H| \(.*\))$/g, '') } }