diff --git a/dist/index.js b/dist/index.js index 9b6e0d7..d0e0dba 100644 --- a/dist/index.js +++ b/dist/index.js @@ -6,7 +6,7 @@ function newRidgeState(iv, o) { let sb = []; let v = iv; let set = (ns, ac, ca) => { - v = (v instanceof Function ? ns(v) : ns); + v = (ns instanceof Function ? ns(v) : ns); ca && ca(v); setTimeout(() => { sb.forEach((c) => c !== ca && c(v)); diff --git a/package.json b/package.json index dd25065..868d340 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-ridge-state", - "version": "4.0.0", + "version": "4.0.1", "description": "react-ridge-state is a very simple global state management library for React and React Native", "main": "dist/index.js", "types": "dist/index.d.ts",