mirror of https://github.com/langgenius/dify.git
add socket edit permission validate
This commit is contained in:
parent
9be496f953
commit
bdac6f91dd
|
|
@ -49,6 +49,8 @@ def socket_connect(sid, environ, auth):
|
|||
user = AccountService.load_logged_in_account(account_id=user_id)
|
||||
if not user:
|
||||
return False
|
||||
if not user.has_edit_permission:
|
||||
return False
|
||||
|
||||
collaboration_service.save_session(sid, user)
|
||||
return True
|
||||
|
|
|
|||
Loading…
Reference in New Issue