Explorar el Código

check directive bound status in v-model listener (fix #2023)

Evan You hace 10 años
padre
commit
f9bbd20c90
Se han modificado 1 ficheros con 3 adiciones y 1 borrados
  1. 3 1
      src/directives/public/model/text.js

+ 3 - 1
src/directives/public/model/text.js

@@ -60,7 +60,9 @@ export default {
 
     // Now attach the main listener
     this.listener = function () {
-      if (composing) return
+      if (composing || !self._bound) {
+        return
+      }
       var val = number || isRange
         ? toNumber(el.value)
         : el.value