Browse Source

fix: lint warning

Tienson Qin 2 years ago
parent
commit
facee3fbc4
2 changed files with 0 additions and 5 deletions
  1. 0 3
      src/electron/electron/search.cljs
  2. 0 2
      src/main/frontend/handler/search.cljs

+ 0 - 3
src/electron/electron/search.cljs

@@ -301,7 +301,6 @@
   (when-let [database (get-db repo)]
     (when-not (string/blank? q)
       (let [match-inputs (get-match-inputs q)
-            non-match-input (str "%" (string/replace q #"\s+" "%") "%")
             limit  (or limit 20)
             ;; https://www.sqlite.org/fts5.html#the_highlight_function
             ;; the 2nd column in pages_fts (content)
@@ -311,8 +310,6 @@
             select (str "select rowid, uuid, content, " snippet-aux " from pages_fts where ")
             match-sql (str select
                            " content match ? order by rank limit ?")
-            non-match-sql (str select
-                               " content like ? limit ?")
             matched-result (->>
                             (map
                               (fn [match-input]

+ 0 - 2
src/main/frontend/handler/search.cljs

@@ -9,8 +9,6 @@
             [frontend.util :as util]
             [promesa.core :as p]
             [logseq.graph-parser.text :as text]
-            [frontend.util.drawer :as drawer]
-            [frontend.util.property :as property]
             [electron.ipc :as ipc]
             [goog.functions :refer [debounce]]
             [dommy.core :as dom]))