Skip to content

Commit 05207a3

Browse files
committed
Update index.js
Splice too much?
1 parent 286ae93 commit 05207a3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/observer/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ p.convert = function (key, val) {
181181
var oldChildOb = val && val.__ob__
182182
if (oldChildOb) {
183183
var oldBindings = oldChildOb.bindings
184-
oldBindings.splice(oldBindings.indexOf(binding))
184+
oldBindings.splice(oldBindings.indexOf(binding),1)
185185
}
186186
val = newVal
187187
// add binding to new value
@@ -232,4 +232,4 @@ p.removeVm = function (vm) {
232232
this.vms.splice(this.vms.indexOf(vm), 1)
233233
}
234234

235-
module.exports = Observer
235+
module.exports = Observer

0 commit comments

Comments
 (0)