diff --git a/README.md b/README.md index f3a933b..84fbdfe 100644 --- a/README.md +++ b/README.md @@ -84,7 +84,7 @@ Here's an example: ```clojure (def open-validation-fsm - ^{:open? true} + ^{::rs/open? true} {:id :validation-open :initial ::clean :states {::clean {:on {::edit-started ::editing}} diff --git a/src/re_statecharts/core.cljc b/src/re_statecharts/core.cljc index 15281f6..22a5077 100644 --- a/src/re_statecharts/core.cljc +++ b/src/re_statecharts/core.cljc @@ -117,9 +117,10 @@ (defn integrate ([machine] (integrate machine sc.rf/default-opts)) - ([{:keys [id] :as machine} {:keys [clock] :as opts}] + ([{:keys [id] :as machine} + {::keys [open?] + :keys [clock] :as opts}] (let [clock (or clock (clock/wall-clock)) - open? (:open? opts) machine (assoc machine :scheduler (Scheduler. id (atom {}) clock open?)) transition-opts (cond-> (:transition-opts opts) open? (assoc :ignore-uknown-events? true))]