fix: lint warnings

pull/10839/head
Tienson Qin 2023-12-28 21:31:07 +08:00
parent 4016f93884
commit 559e38ac50
7 changed files with 15 additions and 10 deletions

View File

@ -1,4 +1,5 @@
(ns frontend.handler.worker (ns frontend.handler.worker
"Handle messages received from the db worker"
(:require [cljs-bean.core :as bean] (:require [cljs-bean.core :as bean]
[frontend.handler.file :as file-handler] [frontend.handler.file :as file-handler]
[frontend.handler.notification :as notification] [frontend.handler.notification :as notification]

View File

@ -1,4 +1,5 @@
(ns frontend.modules.file.core (ns frontend.modules.file.core
"Convert block trees to content"
(:require [clojure.string :as string] (:require [clojure.string :as string]
[frontend.db :as db] [frontend.db :as db]
[frontend.state :as state] [frontend.state :as state]

View File

@ -85,16 +85,15 @@
(when-not (:pipeline-replace? tx-meta) ; from db worker (when-not (:pipeline-replace? tx-meta) ; from db worker
(let [tx-meta' (pr-str tx-meta) (let [tx-meta' (pr-str tx-meta)
tx-data' (pr-str tx-data) tx-data' (pr-str tx-data)
context (if (config/db-based-graph? repo) context {:dev? config/dev?
{:dev? config/dev? :validate-db-options (:dev/validate-db-options (state/get-config))
:validate-db-options (:dev/validate-db-options (state/get-config))} :importing? (:graph/importing @state/state)
{:importing? (:graph/importing @state/state) :date-formatter (state/get-date-formatter)
:date-formatter (state/get-date-formatter) :export-bullet-indentation (state/get-export-bullet-indentation)
:export-bullet-indentation (state/get-export-bullet-indentation) :preferred-format (state/get-preferred-format)
:preferred-format (state/get-preferred-format) :journals-directory (config/get-journals-directory)
:journals-directory (config/get-journals-directory) :whiteboards-directory (config/get-whiteboards-directory)
:whiteboards-directory (config/get-whiteboards-directory) :pages-directory (config/get-pages-directory)}]
:pages-directory (config/get-pages-directory)})]
(if sqlite (if sqlite
(p/let [result (.transact sqlite repo tx-data' tx-meta' (p/let [result (.transact sqlite repo tx-data' tx-meta'
(pr-str context)) (pr-str context))

View File

@ -1,4 +1,5 @@
(ns frontend.worker.date (ns frontend.worker.date
"Date related fns that used by worker"
(:require [cljs-time.format :as tf] (:require [cljs-time.format :as tf]
[logseq.graph-parser.util :as gp-util])) [logseq.graph-parser.util :as gp-util]))

View File

@ -1,4 +1,5 @@
(ns frontend.worker.file.core (ns frontend.worker.file.core
"Save file to disk"
(:require [clojure.string :as string] (:require [clojure.string :as string]
[frontend.worker.file.util :as wfu] [frontend.worker.file.util :as wfu]
[frontend.worker.file.property-util :as property-util] [frontend.worker.file.property-util :as property-util]

View File

@ -1,4 +1,5 @@
(ns frontend.worker.file.util (ns frontend.worker.file.util
"File name fns"
(:require [clojure.string :as string] (:require [clojure.string :as string]
[logseq.graph-parser.util :as gp-util] [logseq.graph-parser.util :as gp-util]
[frontend.worker.util :as util])) [frontend.worker.util :as util]))

View File

@ -1,4 +1,5 @@
(ns frontend.worker.state (ns frontend.worker.state
"State hub for worker"
(:require [frontend.worker.util :as worker-util])) (:require [frontend.worker.util :as worker-util]))
(defonce *state (atom {:db/latest-transact-time {} (defonce *state (atom {:db/latest-transact-time {}