mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-13 21:05:19 +00:00
fix: tools permissions
This commit is contained in:
parent
7a70fd1312
commit
31ed1fcdb8
1 changed files with 1 additions and 1 deletions
|
|
@ -70,7 +70,7 @@ async def create_new_tools(
|
||||||
user=Depends(get_verified_user),
|
user=Depends(get_verified_user),
|
||||||
):
|
):
|
||||||
if user.role != "admin" and not has_permission(
|
if user.role != "admin" and not has_permission(
|
||||||
user.id, "workspace.knowledge", request.app.state.config.USER_PERMISSIONS
|
user.id, "workspace.tools", request.app.state.config.USER_PERMISSIONS
|
||||||
):
|
):
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=status.HTTP_401_UNAUTHORIZED,
|
status_code=status.HTTP_401_UNAUTHORIZED,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue