EntityPublishedActionDeriver.php in Drupal 10
File
core/lib/Drupal/Core/Action/Plugin/Action/Derivative/EntityPublishedActionDeriver.php
View source
<?php
namespace Drupal\Core\Action\Plugin\Action\Derivative;
use Drupal\Core\Entity\EntityPublishedInterface;
use Drupal\Core\Entity\EntityTypeInterface;
class EntityPublishedActionDeriver extends EntityActionDeriverBase {
protected function isApplicable(EntityTypeInterface $entity_type) {
return $entity_type
->entityClassImplements(EntityPublishedInterface::class);
}
}