mirror of
https://github.com/apache/superset.git
synced 2026-06-08 09:09:27 +00:00
fix: dashboard ownership check (#24249)
This commit is contained in:
@@ -42,7 +42,7 @@ const isUserDashboardOwner = (
|
||||
user: UserWithPermissionsAndRoles | UndefinedUser,
|
||||
) =>
|
||||
isUserWithPermissionsAndRoles(user) &&
|
||||
dashboard.owners.some(owner => owner.username === user.username);
|
||||
dashboard.owners.some(owner => owner.id === user.userId);
|
||||
|
||||
export const canUserEditDashboard = (
|
||||
dashboard: Dashboard,
|
||||
|
||||
Reference in New Issue
Block a user