Hi, I trying to make new rule and stuck with removing multiline comment.
It looks like:
/**
* @DI\InjectParams({
* "repository" = @DI\Inject("repository"),
* "option" = @DI\Inject("%option%"),
* })
*/
I use
$inf = $constructMethod->getAttribute(AttributeKey::PHP_DOC_INFO);
$inf->removeByName('DI');
but this command removes only 1 line
---------- begin diff ----------
--- Original
+++ New
@@ -21,7 +21,6 @@
/**
- * @DI\InjectParams({
* "repository" = @DI\Inject("repository"),
* "option" = @DI\Inject("%option%"),
* })
----------- end diff -----------
Also I tried to make custom TagValueNode, but didn't find a way to registered new PhpDocNodeFactory.
Need help :)
rector version dev-master(v0.7.0)
Hi, I trying to make new rule and stuck with removing multiline comment.
It looks like:
I use
but this command removes only 1 line
Also I tried to make custom TagValueNode, but didn't find a way to registered new PhpDocNodeFactory.
Need help :)
rector version dev-master(v0.7.0)