Remove unreachable keyed node logic, fixes #2597 (#2673)

This commit is contained in:
Barney Carroll 2021-04-18 18:14:21 +01:00 committed by GitHub
parent 3b1bc04b9e
commit ade77f37c9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -282,7 +282,6 @@ module.exports = function($window) {
var start = 0, oldStart = 0
if (!isOldKeyed) while (oldStart < old.length && old[oldStart] == null) oldStart++
if (!isKeyed) while (start < vnodes.length && vnodes[start] == null) start++
if (isKeyed === null && isOldKeyed == null) return // both lists are full of nulls
if (isOldKeyed !== isKeyed) {
removeNodes(parent, old, oldStart, old.length)
createNodes(parent, vnodes, start, vnodes.length, hooks, nextSibling, ns)