Commit ee1e56d2 authored by Martin Anderson-Clutz's avatar Martin Anderson-Clutz
Browse files

Issue #3243589 by Abdelrahman Amer, mandclu: Warning when trying to translate...

Issue #3243589 by Abdelrahman Amer, mandclu: Warning when trying to translate entity that had svg image field and not translatable with option hide field if not translatable
parent 6d0edaf1
Loading
Loading
Loading
Loading
+1 −1
Changes for src/Plugin/Field/FieldWidget/SvgImageFieldWidget.php: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -283,7 +283,7 @@ public static function validateRequiredFields($element, FormStateInterface $form
      $image_field = NestedArray::getValue($form_state->getUserInput(), $parents);
      // We check for the array key, so that it can be NULL (like if the user
      // submits the form without using the "upload" button).
      if (!array_key_exists($field, $image_field)) {
      if (empty($image_field) || !is_array($image_field) || !array_key_exists($field, $image_field)) {
        return;
      }
    }