implments cronjob to do the sheet archiving

This commit is contained in:
msramalho
2025-02-07 16:53:33 +00:00
parent fed8543c30
commit eccd71d168
7 changed files with 93 additions and 16 deletions

View File

@@ -17,7 +17,7 @@ default_router = APIRouter()
@default_router.get("/")
async def home(request: Request):
# TODO: maybe split into 2 routes: one non authenticated and one authenticated for the groups info only
# TODO: maybe split into 2 routes: one non authenticated and one authenticated for the groups info only, necessary only for the extension
status = {"version": VERSION, "breakingChanges": BREAKING_CHANGES}
try:
email = await get_user_auth(await bearer_security(request))

View File

@@ -67,7 +67,6 @@ def archive_user_sheet(
if not sheet:
raise HTTPException(status_code=403, detail="No access to this sheet.")
# TODO: what happens if user is taken out of group after sheet is created? this should be checked in a cronjob that notifies the user
if not user.in_group(sheet.group_id):
raise HTTPException(status_code=403, detail="User does not have access to this group.")