Still on Drupal 7? Security support for Drupal 7 ended on 5 January 2025. Please visit our Drupal 7 End of Life resources page to review all of your options.
Running drupal-check on the codebase shows the following:
------ --------------------------------------------------------
Line src/BadgeListBuilder.php
------ --------------------------------------------------------
90 Access to an undefined property
Drupal\Core\Entity\EntityInterface::$image.
94 Access to an undefined property
Drupal\Core\Entity\EntityInterface::$image.
102 Call to an undefined method
Drupal\Core\Entity\EntityInterface::getBadgeWeight().
104 Call to an undefined method
Drupal\Core\Entity\EntityInterface::getBadgeRoleIds().
------ --------------------------------------------------------
------ ---------------------------------------------------------------------
Line src/Controller/BadgeController.php
------ ---------------------------------------------------------------------
38 PHPDoc tag @param has invalid value
(\Drupal\Core\Utility\LinkGeneratorInterface linkGenerator
Link generator service.): Unexpected token "linkGenerator",
expected variable at offset 107
56 PHPDoc tag @return has invalid value ([]
Return links for badge creation.): Unexpected token "[", expected
type at offset 36
------ ---------------------------------------------------------------------
------ ---------------------------------------------------------------------
Line src/Controller/UserBadgesListBuilder.php
------ ---------------------------------------------------------------------
38 Property Drupal\user_badges\Controller\UserBadgesListBuilder::$user
has unknown class Drupal\user\User as its type.
💡 Learn more at https://phpstan.org/user-guide/discovering-symbols
------ ---------------------------------------------------------------------
------ ------------------------------------------------------------------
Line src/Entity/Badge.php
------ ------------------------------------------------------------------
97 Access to an undefined property
Drupal\Core\Field\FieldItemInterface::$target_id.
110 Method Drupal\user_badges\Entity\Badge::setBadgeRoleId() should
return Drupal\user_badges\BadgeInterface but return statement is
missing.
------ ------------------------------------------------------------------
------ -----------------------------------------------------------------------
Line src/Entity/Form/BadgeForm.php
------ -----------------------------------------------------------------------
45 Call to an undefined static method
Drupal\Core\Entity\ContentEntityForm::submit().
69 Method Drupal\user_badges\Entity\Form\BadgeForm::save() should return
int but return statement is missing.
------ -----------------------------------------------------------------------
------ --------------------------------------------------------------------
Line src/Form/BadgeTypeForm.php
------ --------------------------------------------------------------------
69 Method Drupal\user_badges\Form\BadgeTypeForm::save() should return
int but return statement is missing.
------ --------------------------------------------------------------------
------ --------------------------------------------------------------------
Line src/Plugin/RulesAction/AssignBadge.php
------ --------------------------------------------------------------------
36 Parameter $account of method
Drupal\user_badges\Plugin\RulesAction\AssignBadge::doexecute() has
invalid type Drupal\user_badges\Plugin\RulesAction\UserInterface.
------ --------------------------------------------------------------------
[ERROR] Found 13 errors
Comment | File | Size | Author |
---|---|---|---|
#4 | user_badges-3314456-4.patch | 2.91 KB | myha |
#3 | user_badges-3314456-3.patch | 511 bytes | myha |
#2 | user_badges-n3314456-2.patch | 382 bytes | damienmckenna |
Issue fork user_badges-3314456
Show commands
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:
- 3314456-drupal10 changes, plain diff MR !2
Comments
Comment #2
damienmckennaInitial change to the info file.
Comment #3
myha CreditAttribution: myha commentedUpdate of the @damienmckenna patch.
Comment #4
myha CreditAttribution: myha commentedAn extra fixes, addition to previous patch (user_badges-3314456-3.patch).