Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Issue forks
drupal-2570593
Commits
36aa29e0
Commit
36aa29e0
authored
May 14, 2021
by
Moshe Weitzman
Committed by
Moshe Weitzman
May 14, 2021
Browse files
Rename usages to entities_by_class.
parent
c64c7a75
Changes
1
Hide whitespace changes
Inline
Side-by-side
core/lib/Drupal/Core/Entity/EntityStorageBase.php
View file @
36aa29e0
...
...
@@ -361,9 +361,9 @@ protected function preLoad(array &$ids = NULL) {
* Associative array of query results, keyed on the entity ID.
*/
protected
function
postLoad
(
array
&
$entities
)
{
$entity_class
es
=
$this
->
getEntitiesByClass
(
$entities
);
$entit
ies_b
y_class
=
$this
->
getEntitiesByClass
(
$entities
);
foreach
(
$entity_class
es
as
$entity_class
=>
&
$items
)
{
foreach
(
$entit
ies_b
y_class
as
$entity_class
=>
&
$items
)
{
$entity_class
::
postLoad
(
$this
,
$entities
);
// Call hook_entity_load().
...
...
@@ -422,10 +422,10 @@ public function delete(array $entities) {
return
;
}
$entity_class
es
=
$this
->
getEntitiesByClass
(
$entities
);
$entit
ies_b
y_class
=
$this
->
getEntitiesByClass
(
$entities
);
// Allow code to run before deleting.
foreach
(
$entity_class
es
as
$entity_class
=>
&
$items
)
{
foreach
(
$entit
ies_b
y_class
as
$entity_class
=>
&
$items
)
{
$entity_class
::
preDelete
(
$this
,
$items
);
foreach
(
$items
as
$entity
)
{
$this
->
invokeHook
(
'predelete'
,
$entity
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment