- Issue created by @capysara
- πΊπΈUnited States capysara
Added a MR to remove the "final" to allow overrides.
- πΊπΈUnited States swirt Florida
@capysara, that is a good question. That change to final came in with some phpstan fixes here . Frankly I didn't understand phpstan's reason for calling it out at the time. Let me investigate this a bit more today (after I've had mee coffee). I am not opposed to changing it back like you've done. The part that is interesting and that I have not figured out yet is that phpstan originally called it out as needing to be final, but it is not re-flagging it on your commit. Makes me wonder if phpstan has fixed an overlay aggressive standard. I'll look into this some more today.
- πΊπΈUnited States capysara
Possibly phpstan was calling out because some of the namespaces were missing the backslash and interpreted as relative to the context of the module's namespace? When I extended the __construct method in my batch script, the ones without it were flagged in drupal-check, for example,
Parameter $state of method Drupal\mymodule\cbo_scripts\LocationsBatchScript::__construct() has invalid type Drupal\codit_batch_operations\Drupal\Core\State\State.
- πΊπΈUnited States swirt Florida
@capysara thank you for this contribution. I will release it today to you can be unblocked.
I am curious what service you needed to inject. If you think it would be useful to others I'd be happy to add it it to the base class.
- πΊπΈUnited States capysara
what service you needed to inject
It was my custom service. Nothing reusable for others.
Thanks for the quick turnaround! I really appreciate it.