mirror of https://github.com/apache/superset.git
fix: dashboard ownership check (#24249)
This commit is contained in:
parent
9e3875cd9b
commit
7e70f19b68
|
@ -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,
|
||||
|
|
Loading…
Reference in New Issue