Skip to content

Commit

Permalink
Merge pull request #162 from idugan100/slow_page_load_due_to_regex
Browse files Browse the repository at this point in the history
code regex more strict to reduce false positive matches that need db query
  • Loading branch information
kandasamyc authored Apr 25, 2024
2 parents 92f770d + 61ab707 commit 3eaf963
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion home/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ class Course(Model):
recent = RecentCourseManager()
unfiltered = Manager()

course_code_format = '[A-Za-z]{4}(?:[A-Za-z]|[0-9]){3,6}'
course_code_format = '[A-Za-z]{4}(?:[0-9]){3,6}'

def save(self, *args, **kwargs):
# `name` is essentially a computed field, and will never have a value
Expand Down

0 comments on commit 3eaf963

Please sign in to comment.