diff --git a/app/routers/applications.py b/app/routers/applications.py index cbf6fa9c..a4264189 100644 --- a/app/routers/applications.py +++ b/app/routers/applications.py @@ -544,10 +544,7 @@ async def lapse_application( Depends( dependencies.get_scoped_application_as_user( roles=(models.UserType.FI,), - statuses=( - models.ApplicationStatus.SUBMITTED, - models.ApplicationStatus.STARTED, - ), + statuses=(models.ApplicationStatus.STARTED,), ) ), ], diff --git a/tests/routers/test_applications.py b/tests/routers/test_applications.py index 1747c4f8..cb76f310 100644 --- a/tests/routers/test_applications.py +++ b/tests/routers/test_applications.py @@ -420,7 +420,7 @@ def test_lapse_application(client, session, lender_header, pending_application): assert response.status_code == status.HTTP_422_UNPROCESSABLE_ENTITY assert response.json() == {"detail": _("Application status should not be %(status)s", status=_("PENDING"))} - pending_application.status = models.ApplicationStatus.SUBMITTED + pending_application.status = models.ApplicationStatus.STARTED session.commit() response = client.post(f"/applications/{pending_application.id}/lapse", headers=lender_header)