Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle write permission correctly when checking for users with access to same site #19199

Merged
merged 1 commit into from May 25, 2022

Conversation

sgiehl
Copy link
Member

@sgiehl sgiehl commented May 9, 2022

Description:

fixes #18692

Review

@sgiehl sgiehl added not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org. Needs Review PRs that need a code review labels May 9, 2022
@sgiehl sgiehl added this to the 4.11.0 milestone May 9, 2022
Copy link
Contributor

@justinvelluppillai justinvelluppillai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While these changes seem sensible I can't reproduce the original issue so it's not possible to confirm this actually fixes the issue. @sgiehl did you manage to reproduce the issue? The original comment says the user was Admin and couldn't copy the dashboard to a View user, so I'm not sure if this solves that.

@justinvelluppillai justinvelluppillai removed the Needs Review PRs that need a code review label May 10, 2022
@sgiehl
Copy link
Member Author

sgiehl commented May 10, 2022

@justinvelluppillai I wasn't able to reproduce with view permission. But guess the users that weren't visible had write and not view permission, which would easily explain the problem.

@sgiehl
Copy link
Member Author

sgiehl commented May 24, 2022

@justinvelluppillai did you do a code review on this one? If so, guess we can merge it, as it should at least fix an issue for users with write permission.

Copy link
Contributor

@justinvelluppillai justinvelluppillai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will approve this on the basis it fixes a potential bug. I've pinged @Starker3 internally to see if it fixes the issue he originally reported also.

@sgiehl
Copy link
Member Author

sgiehl commented May 25, 2022

It definitely fixes a bug. I could reproduce the problem with write permission. Will merge it.

@sgiehl sgiehl merged commit 8198c38 into 4.x-dev May 25, 2022
@sgiehl sgiehl deleted the m18692 branch May 25, 2022 07:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fixes problem where dashboards can't be copied to users in certain circumstances
2 participants