Update code in endpoints/france.post.py
This commit is contained in:
parent
6f43ba16ed
commit
917938bf5b
@ -4,7 +4,7 @@ router = APIRouter()
|
|||||||
|
|
||||||
states_in_france = [
|
states_in_france = [
|
||||||
"Auvergne-Rhône-Alpes",
|
"Auvergne-Rhône-Alpes",
|
||||||
"Bourgogne-Franche-Comté",
|
"Bourgogne-Franche-Comté",
|
||||||
"Bretagne",
|
"Bretagne",
|
||||||
"Centre-Val de Loire",
|
"Centre-Val de Loire",
|
||||||
"Corse",
|
"Corse",
|
||||||
@ -20,7 +20,7 @@ states_in_france = [
|
|||||||
|
|
||||||
@router.post("/france")
|
@router.post("/france")
|
||||||
async def get_states_in_france():
|
async def get_states_in_france():
|
||||||
"""Endpoint that returns list of states in france"""
|
"""Returns list of states in France"""
|
||||||
if request.method != "POST":
|
if request.method != "POST":
|
||||||
raise HTTPException(status_code=405, detail="Method Not Allowed")
|
raise HTTPException(status_code=405, detail="Method Not Allowed")
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user