Merge pull request #670 from zanllp/adjust-api-permissions

Adjust permissions required for API calls
pull/671/head
zanllp 2024-06-24 07:23:17 +08:00 committed by GitHub
commit 5703f9df70
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -296,7 +296,7 @@ def infinite_image_browsing_api(app: FastAPI, **kwargs):
name: str
value: str
@app.post(f"{api_base}/app_fe_setting", dependencies=[Depends(verify_secret)])
@app.post(f"{api_base}/app_fe_setting", dependencies=[Depends(verify_secret), Depends(write_permission_required)])
async def app_fe_setting(req: AppFeSettingReq):
conn = DataBase.get_conn()
GlobalSetting.save_setting(conn, req.name, req.value)