Skip to content

Commit

Permalink
chore: remove unnecessary loop
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Jun 30, 2020
1 parent b3536d8 commit d2bf3cc
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/runtime-core/src/componentSlots.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,9 +130,7 @@ export const updateSlots = (
if (__DEV__ && isHmrUpdating) {
// Parent was HMR updated so slot content may have changed.
// force update slots and mark instance for hmr as well
for (const key in children as RawSlots) {
if (key !== '_') slots[key] = (children as Slots)[key]
}
extend(slots, children as Slots)
} else if (
// bail on dynamic slots (v-if, v-for, reference of scope variables)
!(vnode.patchFlag & PatchFlags.DYNAMIC_SLOTS)
Expand Down

0 comments on commit d2bf3cc

Please sign in to comment.