refactor: use less util/node-test? where possible

also add new ns to kondo lint
This commit is contained in:
Gabriel Horner
2025-04-23 10:10:56 -04:00
parent cdb7c17a8e
commit 762b83a3c9
3 changed files with 4 additions and 2 deletions

View File

@@ -157,6 +157,7 @@
frontend.util.text text-util
frontend.util.thingatpt thingatpt
frontend.util.url url-util
frontend.worker.shared-service shared-service
frontend.worker.handler.page worker-page
frontend.worker.pipeline worker-pipeline
frontend.worker.state worker-state

View File

@@ -327,7 +327,7 @@
[repo {:keys [tx-data tx-meta db-after db-before]}]
(let [{:keys [outliner-op]} tx-meta]
(when (and
(or util/node-test? (= (:client-id tx-meta) (:client-id @state/state)))
(= (:client-id tx-meta) (:client-id @state/state))
outliner-op
(not (false? (:gen-undo-ops? tx-meta)))
(not (:create-today-journal? tx-meta)))

View File

@@ -15,7 +15,8 @@
(defmethod worker-db-listener/listen-db-changes :gen-undo-ops
[_ {:keys [repo]} tx-report]
(undo-redo/gen-undo-ops! repo tx-report))
(undo-redo/gen-undo-ops! repo
(assoc-in tx-report [:tx-meta :client-id] (:client-id @state/state))))
(defn listen-db-fixture
[f]