diff --git a/src/Drupal/Commands/field/FieldDeleteCommands.php b/src/Drupal/Commands/field/FieldDeleteCommands.php index 3e9845b3bd..fa34f498d1 100644 --- a/src/Drupal/Commands/field/FieldDeleteCommands.php +++ b/src/Drupal/Commands/field/FieldDeleteCommands.php @@ -147,9 +147,9 @@ protected function deleteFieldConfig(FieldConfigInterface $fieldConfig): void if ($fieldStorage && !$fieldStorage->isLocked()) { $fieldConfig->delete(); - // If there is only one bundle left for this field storage, it will be + // If there are no bundles left for this field storage, it will be // deleted too, notify the user about dependencies. - if (count($fieldStorage->getBundles()) <= 1) { + if ($fieldStorage->getBundles() === []) { $fieldStorage->delete(); }