06/16 Phase 6 (continue)

This commit is contained in:
2026-06-17 17:06:43 -04:00
parent 479afde2fa
commit 68a842d6b6
26 changed files with 1027 additions and 61 deletions
+1 -1
View File
@@ -19,7 +19,7 @@ def create_report(listing, reporter, reason: ReportReason, note=None):
reason=reason, note=(note or "").strip() or None)
db.session.add(report)
try:
db.session.commit()
db.session.flush()
except IntegrityError:
db.session.rollback()
raise ReportError("you have already reported this listing")