use dependency injection

Created on 1 May 2025, 18 days ago

Problem/Motivation

phpstan reports:

------ ------------------------------------------------------------------------------
Line src/Plugin/QueueWorker/DelayedRequestDispatcher.php
------ ------------------------------------------------------------------------------
82 \Drupal calls should be avoided in classes, use dependency injection instead
82 \Drupal calls should be avoided in classes, use dependency injection instead
------ ------------------------------------------------------------------------------

------ --------------------------------------------------------------------------------------------------------
Line tests/modules/email_confirmer_test/src/MailCollector.php
------ --------------------------------------------------------------------------------------------------------
23 Method Drupal\email_confirmer_test\MailCollector::doMail() should return array but return statement is
missing.
------ --------------------------------------------------------------------------------------------------------

Steps to reproduce

phpstan analyse -l0 email_confirmer

Proposed resolution

Add the two dependencies to the existing create() pattern. In MailCollector::doMail, return an arry.

Remaining tasks

make an MR.

πŸ“Œ Task
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States BenStallings

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024