Signed-off-by: Bryan Frimin <bryan@getprobo.com>
This commit is contained in:
Bryan Frimin
2025-04-23 10:00:48 -07:00
parent ec028e9d17
commit 5b78141821
2 changed files with 21 additions and 22 deletions

View File

@@ -368,6 +368,10 @@ func (s VendorService) CreateRiskAssessment(
UpdatedAt: now,
}
if !req.ExpiresAt.After(now) {
return nil, fmt.Errorf("expiresAt %v must be in the future", req.ExpiresAt)
}
err = s.svc.pg.WithTx(
ctx,
func(tx pg.Conn) error {