Skip to content

Commit

Permalink
Dev/upgrade handbook url (#164)
Browse files Browse the repository at this point in the history
* Upgraded handbook url in config.json to use 2024. Also fixed incorrect url links in the handbook.js command.

* Fixed eslint warnings
  • Loading branch information
abe123442 authored Nov 3, 2023
1 parent b9576b5 commit 0f34280
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions commands/handbook.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ module.exports = {
// study_level,
// school,
// campus,
equivalents,
// equivalents,
raw_requirements,
exclusions,
// handbook_note,
Expand All @@ -74,7 +74,7 @@ module.exports = {
value:
raw_requirements.replace(
/[A-Z]{4}[0-9]{4}/g,
`[$&](${handbookURL}$&)`,
`[$&](${handbookURL}/$&)`,
) || "None",
inline: true,
},
Expand All @@ -86,16 +86,16 @@ module.exports = {
{
name: "Equivalent Courses",
value:
Object.keys(equivalents)
.map((course) => `[${course}](${course})`)
Object.keys(exclusions)
.map((course) => `[${course}](${handbookURL}/${course})`)
.join(", ") || "None",
inline: true,
},
{
name: "Exclusion Courses",
value:
Object.keys(exclusions)
.map((course) => `[${course}](${handbookURL}${course})`)
.map((course) => `[${course}](${handbookURL}/${course})`)
.join(", ") || "None",
inline: true,
},
Expand Down
2 changes: 1 addition & 1 deletion config/handbook.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"apiURL": "https://circlesapi.csesoc.app",
"handbookURL": "https://www.handbook.unsw.edu.au/undergraduate/courses/2022/"
"handbookURL": "https://www.handbook.unsw.edu.au/undergraduate/courses/2024"
}

0 comments on commit 0f34280

Please sign in to comment.