Skip to content

Commit 70b44ca

Browse files
authored
chore(reactivity): remove unecessary array copy (#12400)
1 parent a49858f commit 70b44ca

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

packages/reactivity/src/effectScope.ts

+2-3
Original file line numberDiff line numberDiff line change
@@ -119,9 +119,8 @@ export class EffectScope {
119119
if (this._active) {
120120
this._active = false
121121
let i, l
122-
const effects = this.effects.slice()
123-
for (i = 0, l = effects.length; i < l; i++) {
124-
effects[i].stop()
122+
for (i = 0, l = this.effects.length; i < l; i++) {
123+
this.effects[i].stop()
125124
}
126125
this.effects.length = 0
127126

0 commit comments

Comments
 (0)