Skip to content

Commit

Permalink
bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Ruben-Arushanyan committed Oct 3, 2023
1 parent 0908cd6 commit c519144
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Store.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,9 @@ class Store {
}

subscribe = (cb) => {
this.#emitter.on(cb)
return () => this.#emitter.off(cb)
const _cb = (...args) => cb(args)
this.#emitter.on(_cb)
return () => this.#emitter.off(_cb)
}

subscribeSelector = (selector, cb) => {
Expand Down

0 comments on commit c519144

Please sign in to comment.