Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
workflow
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
workflow
Commits
b35f7db4
Commit
b35f7db4
authored
4 weeks ago
by
John Voskuilen
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#3513033
by spiderman: Too few arguments to function WorkflowEntityHooks::userDelete()
parent
a43fdcb4
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#448792
passed with warnings
4 weeks ago
Stage: build
Stage: validate
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/Entity/WorkflowTargetEntity.php
+1
-1
1 addition, 1 deletion
src/Entity/WorkflowTargetEntity.php
src/Hook/WorkflowEntityHooks.php
+6
-6
6 additions, 6 deletions
src/Hook/WorkflowEntityHooks.php
with
7 additions
and
7 deletions
src/Entity/WorkflowTargetEntity.php
+
1
−
1
View file @
b35f7db4
...
...
@@ -7,7 +7,7 @@ use Drupal\Core\Entity\EntityInterface;
/**
* Provides a wrapper/ decorator for the $transition->getTargetEntity().
*
* @todo Change all st
t
aic functions to non static.
* @todo Change all sta
t
ic functions to non static.
* But a decorator requires duplciating many functions...
*/
class
WorkflowTargetEntity
{
...
...
This diff is collapsed.
Click to expand it.
src/Hook/WorkflowEntityHooks.php
+
6
−
6
View file @
b35f7db4
...
...
@@ -115,7 +115,11 @@ class WorkflowEntityHooks {
}
break
;
case
!
WorkflowTargetEntity
::
isWorkflowEntityType
(
$entity
->
getEntityTypeId
())
:
case
WorkflowTargetEntity
::
isWorkflowEntityType
(
$entity
->
getEntityTypeId
())
:
// A Workflow entity.
break
;
default
:
// A 'normal' entity is deleted.
foreach
(
$fields
=
_workflow_info_fields
(
$entity
)
as
$field_id
=>
$field_storage
)
{
$field_name
=
$field_storage
->
getName
();
...
...
@@ -124,10 +128,6 @@ class WorkflowEntityHooks {
$this
->
deleteTransitionsOfEntity
(
$entity
,
'workflow_transition'
,
$field_name
);
}
break
;
default
:
// A Workflow entity.
break
;
}
}
...
...
@@ -222,7 +222,7 @@ class WorkflowEntityHooks {
* @todo Hook hook_user_delete does not exist. hook_ENTITY_TYPE_delete?
*/
#[Hook('user_delete')]
public
function
userDelete
(
$
edit
,
AccountInterface
$account
,
$method
)
{
public
function
userDelete
(
$
account
)
{
$this
->
userCancel
([],
$account
,
'user_cancel_delete'
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment