Problem/Motivation
drupal-check on version:
176dd7eca67bbce80ca16e37fa3e94323647bf0d
------ ---------------------------------------------------------
Line password_policy_history/password_policy_history.install
------ ---------------------------------------------------------
15 Call to deprecated function entity_load_multiple().
------ ---------------------------------------------------------
------ --------------------------------------------------------
Line password_policy_history/password_policy_history.module
------ --------------------------------------------------------
52 Call to deprecated function db_delete().
------ --------------------------------------------------------
------ -------------------------------------------------------------------------------------
Line src/Controller/PasswordPolicyListBuilder.php
------ -------------------------------------------------------------------------------------
27 Call to deprecated method getLabel() of class Drupal\Core\Entity\EntityListBuilder.
------ -------------------------------------------------------------------------------------
------ -------------------------------------------------------
Line src/EventSubscriber/PasswordPolicyEventSubscriber.php
------ -------------------------------------------------------
53 Call to deprecated function drupal_set_message().
------ -------------------------------------------------------
------ ---------------------------------------------------
Line src/Form/PasswordPolicyDeleteForm.php
------ ---------------------------------------------------
41 Call to deprecated function drupal_set_message().
------ ---------------------------------------------------
------ ---------------------------------------------------
Line src/Form/PasswordReset.php
------ ---------------------------------------------------
119 Call to deprecated function drupal_set_message().
129 Call to deprecated function drupal_set_message().
------ ---------------------------------------------------
------ -------------------------------------------------------------------------------------------
Line src/PasswordConstraintInterface.php
------ -------------------------------------------------------------------------------------------
12 Interface Drupal\password_policy\PasswordConstraintInterface extends deprecated interface
Drupal\Component\Plugin\ConfigurablePluginInterface.
------ -------------------------------------------------------------------------------------------
------ ------------------------------------------------------------
Line src/Tests/PasswordManualResetTest.php
------ ------------------------------------------------------------
45 Call to deprecated method entityManager() of class Drupal.
------ ------------------------------------------------------------
------ ----------------------------------------------------------------------------------------
Line src/Wizard/PasswordPolicyWizard.php
------ ----------------------------------------------------------------------------------------
Class Drupal\ctools\Wizard\EntityFormWizardBase not found and could not be autoloaded.
------ ----------------------------------------------------------------------------------------
[ERROR] Found 10 errors
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
| Comment | File | Size | Author |
|---|---|---|---|
| #10 | 3042612-10.patch | 4.32 KB | kim.pepper |
| #8 | 3042612-interdiff-8.txt | 1.6 KB | kim.pepper |
| #8 | 3042612-8.patch | 6.83 KB | kim.pepper |
| #6 | drupal_9_deprecated_code-3042612-6.patch | 5.39 KB | sergiu stici |
Comments
Comment #2
sergiu stici commentedHere is the patch, please review.
Comment #4
PatashINotFound commentedupdated with latest error related to deprecated code.
Comment #5
PatashINotFound commentedComment #6
sergiu stici commentedI updated the patch.
Comment #8
kim.pepperAlso removes usage of deprecated 'entity_manager' service which didn't get picked up by drupal-check.
Comment #9
aohrvetpv commentedThanks for the patches. #8 no longer applies, I think because some of the lines fixed by the patch were fixed in other issues. I'll try to update it when I can, but a new patch would be appreciated.
Comment #10
kim.pepperRe-roll of #8
Comment #11
jeroentLooking good:
We should replace this by DI, but there are other calls to the global \Drupal project. Marking as RTBC so the maintainer of this module can decide if we should replace this or not.
Comment #13
aohrvetpv commentedThanks for the updated patch and RTBC. I think we could change to use dependency injection for the messages as a separate issue. Removing the
drupal_set_message()calls is an improvement.Comment #14
jeroentCreated followup: #3061507: Remove \Drupal calls in classes. Use dependency injection instead
Comment #15
rosinegrean commented