mirror of
https://code.lenaisten.de/Lenaisten/advent22.git
synced 2024-11-23 08:13:01 +00:00
Umbenennung get_visible_days
This commit is contained in:
parent
f81933946c
commit
0ce4e123d9
1 changed files with 3 additions and 3 deletions
|
@ -32,8 +32,8 @@ async def get_date() -> str:
|
||||||
return date.today().isoformat()
|
return date.today().isoformat()
|
||||||
|
|
||||||
|
|
||||||
@router.get("/number")
|
@router.get("/visible_days")
|
||||||
async def get_number() -> int:
|
async def get_visible_days() -> int:
|
||||||
today = date.today()
|
today = date.today()
|
||||||
|
|
||||||
if today.month == 12:
|
if today.month == 12:
|
||||||
|
@ -48,7 +48,7 @@ async def get_number() -> int:
|
||||||
async def user_can_view(
|
async def user_can_view(
|
||||||
index: int,
|
index: int,
|
||||||
) -> bool:
|
) -> bool:
|
||||||
return index < await get_number()
|
return index < await get_visible_days()
|
||||||
|
|
||||||
|
|
||||||
@router.get(
|
@router.get(
|
||||||
|
|
Loading…
Reference in a new issue