PrivatizeLocalGetterToPropertyRector should not apply to public getters #6636
Closed
Description
Feature Request
Not sure if this is intended behavior or not. But I have a class which implements __toString()
but also have a asString()
method. I have __toString()
calling $this->asString()
so as to not duplicate logic. But this rule removes that method call.
IMO it should only apply to non-public methods.
See here: https://getrector.org/demo/1ebfe3d7-28b3-6972-a5c2-d38491e8fc13