fix directory name
- now saves to ~/.radical-api - made API key parameter for /key/me consistent.
This commit is contained in:
parent
0d6b817ff5
commit
e9fa150618
2 changed files with 3 additions and 3 deletions
|
@ -3,7 +3,7 @@ from datetime import datetime, timedelta
|
||||||
from fastapi.encoders import jsonable_encoder
|
from fastapi.encoders import jsonable_encoder
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
DATA_DIR = Path.home().joinpath(".tracker_api/trackers")
|
DATA_DIR = Path.home().joinpath(".radical-api/trackers")
|
||||||
|
|
||||||
|
|
||||||
def object_hook(dct):
|
def object_hook(dct):
|
||||||
|
|
|
@ -86,6 +86,6 @@ def create_key(name, system_key: APIKey = Depends(get_system_key)):
|
||||||
|
|
||||||
|
|
||||||
@router.get("/key/me")
|
@router.get("/key/me")
|
||||||
def key_info(api_key: APIKey = Depends(get_api_key)):
|
def key_info(access_token: APIKey = Depends(get_api_key)):
|
||||||
data = load_keys()
|
data = load_keys()
|
||||||
return data[api_key]
|
return data[access_token]
|
||||||
|
|
Loading…
Reference in a new issue