fix: can't search

Related to #1754
pull/1803/head
Tienson Qin 2021-05-10 15:17:10 +08:00
parent 7958c6b22d
commit 507e9fb031
1 changed files with 3 additions and 2 deletions

View File

@ -174,9 +174,10 @@
[repo]
(when-let [database (get-db repo)]
(.close database)
(let [[_ db-full-path] (get-db-full-path repo)]
(let [[db-name db-full-path] (get-db-full-path repo)]
(println "Delete search indice: " db-full-path)
(fs/unlinkSync db-full-path))))
(fs/unlinkSync db-full-path)
(swap! databases dissoc db-name))))
(defn query
[repo sql]