From 4dd5a27be37047da95dd03b47e2693c9809c2a25 Mon Sep 17 00:00:00 2001 From: Ruben Arushanyan Date: Wed, 4 Oct 2023 02:54:13 +0400 Subject: [PATCH] bug fix --- src/Store.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/Store.js b/src/Store.js index b1d0315..973e9fd 100644 --- a/src/Store.js +++ b/src/Store.js @@ -28,11 +28,9 @@ class Store { subscribe = (cb) => { cb = memoizeByArgs(cb) - let _order = 0; const _cb = (order) => { - if (order > _order) { + if (order >= this.#order) { cb(this.state, this.prevState) - _order = order } }