From d1a231a6069ee99e7e0ca419bd83c68679f3ce74 Mon Sep 17 00:00:00 2001 From: michplunkett <5885605+michplunkett@users.noreply.github.com> Date: Fri, 20 Dec 2024 00:39:38 -0600 Subject: [PATCH] Assignment --- OpenOversight/app/models/database.py | 8 ++++---- OpenOversight/tests/test_models.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/OpenOversight/app/models/database.py b/OpenOversight/app/models/database.py index c367d7b78..b60ad5a9a 100644 --- a/OpenOversight/app/models/database.py +++ b/OpenOversight/app/models/database.py @@ -406,7 +406,7 @@ class Assignment(BaseModel, TrackUpdates): resign_date = db.Column(db.Date, index=True, unique=False, nullable=True) def __repr__(self): - return f"" + return f"" @property def start_date_or_min(self): @@ -656,13 +656,13 @@ class Link(BaseModel, TrackUpdates): author = db.Column(db.String(255), nullable=True) has_content_warning = db.Column(db.Boolean, nullable=False, default=False) - def __repr__(self): - return f"" - @validates("url") def validate_url(self, key, url): return url_validator(url) + def __repr__(self): + return f"" + class Incident(BaseModel, TrackUpdates): __tablename__ = "incidents" diff --git a/OpenOversight/tests/test_models.py b/OpenOversight/tests/test_models.py index 8e5ade98c..77fef7cd3 100644 --- a/OpenOversight/tests/test_models.py +++ b/OpenOversight/tests/test_models.py @@ -137,7 +137,7 @@ def test_assignment_repr(mockdata): assignment = Assignment.query.first() assert ( repr(assignment) - == f"" + == f"" )