Closed (fixed)
Project:
Domain
Version:
3.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
21 Jul 2026 at 10:04 UTC
Updated:
5 Aug 2026 at 12:25 UTC
Jump to comment: Most recent
phpstan-drupal has a new EntityHandlerDirectInjectionRule, see:
Remove direct injection of entity storage
None
None
None
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #9
mably commented@yusuf_khan thanks for your help, but I'll work on this myself.
Comment if you see anything missing.
Comment #11
yusuf_khan commentedsure @mably
Comment #12
mably commentedComment #13
nitinkumar_7 commentedTested locally, existing tests pass against 3.x-dev.
The refactor is clean - swapping direct storage injection for EntityTypeManagerInterface plus lazy xStorage() accessors across the codebase, in line with the EntityHandlerDirectInjectionRule.
In DomainAliasValidator.php, I only see an aliasStorage() accessor added no matching domainStorage() method. If $this->domainStorage is still referenced anywhere in that file, it would now fail since the property no longer exists. Could someone confirm this was handled?
Some classes (DomainAccessControlHandler, Plugin/views/access/Domain, DomainAccessActionBase, DomainAccessContent) changed constructor parameter types rather than just dropping a property. Shouldn't affect normal Drupal usage since these go through create()/createInstance(), but flagging in case it affects the "API changes: None" note in the summary.
Everything else passed locally without issue.
Comment #18
mably commented