lint/style/require-parent-visibility
In the lint-strict preset. In Rector’s rector/coding-style set. Safe fix.
What it does
Make method visibility same as parent one
Configuration
[lint.rules]
"style/require-parent-visibility" = "error"
To skip it in some files or lines, add an override or an ignore comment.