Fix method of /restore API

This commit is contained in:
IamSarina
2025-02-22 11:33:13 +03:30
committed by GitHub
parent a060fd18fe
commit d2527564d8

View File

@ -183,7 +183,7 @@ async def backup_api():
raise HTTPException(status_code=500, detail=f'Error: {str(e)}')
@router.get('/restore', response_model=DetailResponse, summary='Restore Hysteria2 Configuration')
@router.post('/restore', response_model=DetailResponse, summary='Restore Hysteria2 Configuration')
async def restore_api(f: UploadFile = File(...)):
try:
dst_dir_path = '/opt/hysbackup/' # TODO: get this path from .env