[#4] Fix KeyError in authenticate_agency
Some checks failed
Amarillo/amarillo-gitea/amarillo-core/pipeline/head There was a failure building this commit
Some checks failed
Amarillo/amarillo-gitea/amarillo-core/pipeline/head There was a failure building this commit
This commit is contained in:
parent
bbba8de7ac
commit
e81dbbc39c
|
|
@ -40,7 +40,7 @@ async def verify_optional_api_key(X_API_Key: Optional[str] = Header(None)):
|
||||||
|
|
||||||
def authenticate_agency(agency_id: str, password: str):
|
def authenticate_agency(agency_id: str, password: str):
|
||||||
agency_conf_service : AgencyConfService = container['agencyconf']
|
agency_conf_service : AgencyConfService = container['agencyconf']
|
||||||
agency_conf = agency_conf_service.agency_id_to_agency_conf[agency_id]
|
agency_conf = agency_conf_service.agency_id_to_agency_conf.get(agency_id, None)
|
||||||
if not agency_conf:
|
if not agency_conf:
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue