chengwl 1 주 전
부모
커밋
ca9c664bfd
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      packages/Longyi/Core/src/Type/FlexibleVariant.php

+ 4 - 0
packages/Longyi/Core/src/Type/FlexibleVariant.php

@@ -72,6 +72,10 @@ class FlexibleVariant extends AbstractType
     {
         $product = parent::update($data, $id, $attribute);
 
+        if (is_array($attribute) && $attribute !== []) {
+            return $product;
+        }
+
         if (isset($data['options']) && is_array($data['options'])) {
             $syncData = [];