Skip to content

Commit b484881

Browse files
committed
Update StyleStore.ts
1 parent 56df2bb commit b484881

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/base/src/stores/StyleStore.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ function subscribe(listener: () => void) {
4242
listeners.push(listener);
4343

4444
return () => {
45-
const index = listeners.findIndex((l) => l === listener);
46-
if (index >= 0) {
45+
const index = listeners.indexOf(listener);
46+
if (index !== -1) {
4747
listeners.splice(index, 1);
4848
}
4949
};

0 commit comments

Comments
 (0)