-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Unresolvable showIn deprecation case #7642
Comments
Funny thing to notice, both I think this issue could be a valid reason to remove the I would,
Wdyt @sonata-project/contributors ? |
If you can take a look at #7658, it should fix your issue @soullivaneuh |
Currently not because it is not set on our company high priority list. I'll notice if that change. |
I already did the PR, can you take a look at #7658 ? |
Well, you know. Getting older. 🙃 |
Environment
Sonata packages
show
Symfony packages
show
PHP version
Subject
The
Abstract::showIn
was considered as final since #7266.According to my code search (nothing found on the upgrade), we have to use
getPermissionsShow
instead.However, this does not fit cases where the
showIn
result does not rely on permission but on the context.Minimal repository with the bug
Steps to reproduce
I refactored this logic:
Onto:
Expected results
As it works with the old logic, the related admin should not appear on the dashboard context (e.g. on the create navbar super button).
Actual results
The new logic as new effect and I see the reference of the target admin on the dashboard context.
Also. returning roles looks more hacky than the original way as the show behavior does not relate to security here.
I may understand the original usage was wrong (and old). However, it is possible to do that and breaking for v4.0. An upgrade guide for that kind of cases would be awesome.
Best regards
The text was updated successfully, but these errors were encountered: