Skip to content

Commit

Permalink
fix: faculty W parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
l3d00m committed Sep 19, 2024
1 parent d76ccd8 commit 459a9e4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion sked_parser/scraper.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,10 @@ def get_links(overview_url, auth, faculty=""):
continue
if valid_url_regex.match(part_url):
desc = this_url.text.strip()
# Prepend the content of the previous paragraph to the description because it contains the real name of the plan
if "Wirtschaft" in faculty:
desc = this_url.parent.parent.find('summary').text.strip() + " " + desc
if "Recht" in faculty:
# Prepend the content of the previous paragraph to the description because it contains the real name of the plan
if this_url.parent.parent.name == "ol":
desc = this_url.parent.parent.previous + " " + desc
tables.add((desc, part_url))
Expand Down

0 comments on commit 459a9e4

Please sign in to comment.