maker-bundle
maker-bundle copied to clipboard
Changed behaviour of Str::addSuffix so it doesn't care about duplicate suffixes
This PR tries to resolve the issue: https://github.com/symfony/maker-bundle/issues/964
I'm still not sure why Str::addSuffix
wanted to be sure that suffix is not added twice. So, let someone with bigger knowledge of the bundle and class name generation review the PR :)
Thanks!
We should maybe have "addPrefix()" and "ensurePrefix()", where add adds it no matter the string looks before and ensure ensures it is only added once?
EnsureEnd() is the method used in Symfony string component