Skip to content

Commit

Permalink
Fix: apply suggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
Rotheem committed Jan 14, 2025
1 parent 4411f58 commit 176ccf9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions app/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -205,14 +205,14 @@ def initialize_schools(
db_school = models_core.CoreSchool(
id=school.value,
name=school.name,
email_regex=".*",
email_regex="null",
)

try:
initialization.create_school_sync(school=db_school, db=db)
except IntegrityError as error:
hyperion_error_logger.fatal(
f"Startup: Could not add group {db_school.name}<{db_school.id}> in the database: {error}",
f"Startup: Could not add school {db_school.name}<{db_school.id}> in the database: {error}",
)


Expand Down
4 changes: 2 additions & 2 deletions app/core/models_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,8 @@ class CoreSchool(Base):
__tablename__ = "core_school"

id: Mapped[PrimaryKey]
name: Mapped[str] = mapped_column(String, unique=True)
email_regex: Mapped[str] = mapped_column(String)
name: Mapped[str] = mapped_column(unique=True)
email_regex: Mapped[str]


class CoreAssociationMembership(Base):
Expand Down

0 comments on commit 176ccf9

Please sign in to comment.