Create rule for 'Term::getVocabularyId()' deprecated method

Created on 22 September 2021, about 3 years ago
Updated 7 February 2024, 9 months ago

Drupal version

Core 9.x

Drupal Rector version

0.11.3

Problem / Motivation

Call to undefined method Drupal\taxonomy\Entity\Term::getVocabularyId() in Drupal\unique_entity_title\Plugin\Validation\Constraint\UniqueEntityTitleValidator->validate()

When using Drupal 9, getVocabularyId() has been removed from Drupal 9.

Proposed resolution

Replace getVocabularyId() with bundle().

Feature request
Status

Active

Component

Code

Created by

🇬🇧United Kingdom technoveltyco

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇦🇷Argentina cesarmiquel

    Is somebody working on this? I hit this issue so I'd like the rule to be added. I volunteer to try to do it if someone can point me to a similar rule I can use as reference.

Production build 0.71.5 2024