webprofiler module passes in a wrapped object that uses the interface.

Using the interface instead of the class will resolve this.

PHP Fatal error:  Uncaught TypeError: Argument 1 passed to Drupal\fullcalendar_view\TaxonomyColor::__construct() must be an instance of Drupal\Core\Entity\EntityTypeManager, instance of Drupal\webprofiler\Entity\EntityManagerWrapper given, called in core/lib/Drupal/Component/DependencyInjection/Container.php on line 262 and defined in modules/contrib/fullcalendar_view/src/TaxonomyColor.php:19
Stack trace:
#0 core/lib/Drupal/Component/DependencyInjection/Container.php(262): Drupal\fullcalendar_view\TaxonomyColor->__construct(Object(Drupal\webprofiler\Entity\EntityManagerWrapper))
#1 core/lib/Drupal/Component/DependencyInjection/Container.php(171): Drupal\Component\DependencyInjection\Container->createService(Array, 'fullcalendar_vi...')
#2 modules/contrib/fullcalendar_view/src/Plugin/views/style/FullCalendarDisplay.php(57): Drupal\Component\DependencyInjection\Container->get('fullcalendar_vi...')
#3 / in modules/contrib/fullcalendar_view/src/TaxonomyColor.php on line 19
CommentFileSizeAuthor
#2 3018414-2.patch646 bytesjoelpittet

Comments

joelpittet created an issue. See original summary.

joelpittet’s picture

Status: Active » Needs review
StatusFileSize
new646 bytes

Here's a patch to help with this

  • Mingsong committed 243fdaa on 8.x-2.x authored by joelpittet
    Issue #3018414 by joelpittet: Use EntityTypeManagerInterface for...
mingsong’s picture

Hi Joel,

Thanks so much for your patch.

I just pushed it to Dev branch.

Cheers,

joelpittet’s picture

Status: Needs review » Fixed

Great! 🎉 thanks @Mingsong!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.