]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
chore: fix test utils test failing
authordaiwei <daiwei521@126.com>
Sat, 12 Oct 2024 07:40:09 +0000 (15:40 +0800)
committerdaiwei <daiwei521@126.com>
Sat, 12 Oct 2024 07:40:09 +0000 (15:40 +0800)
packages/runtime-dom/src/directives/vModel.ts

index a3a68b78f7f5f3069b2c04164aeffa44b6ac2cf0..64d589ac56cef91fc07d72a92c6240a089caf4d5 100644 (file)
@@ -248,7 +248,7 @@ export const vModelSelect: ModelDirective<HTMLSelectElement, 'number'> = {
 }
 
 function setSelected(el: HTMLSelectElement, value: any) {
-  if (looseEqual(value, (el as any)._cachedValue)) {
+  if ((el as any)._assigning && looseEqual(value, (el as any)._cachedValue)) {
     return
   }
   ;(el as any)._cachedValue = isArray(value)