aboutsummaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorGabriel A. Giovanini <mail@gabrielgio.me>2024-04-25 22:31:01 +0200
committerGabriel A. Giovanini <mail@gabrielgio.me>2024-04-25 22:31:01 +0200
commit65fd7bc9218f1bb0b4a5dd8d8141239b3211e1cd (patch)
tree66902f9d4932a4aae43d72aab003ee14d3f8b8c5 /db
parentb7ca1117b18e228b84dd62a677a0a2ca52b3c549 (diff)
downloaddict-65fd7bc9218f1bb0b4a5dd8d8141239b3211e1cd.tar.gz
dict-65fd7bc9218f1bb0b4a5dd8d8141239b3211e1cd.tar.bz2
dict-65fd7bc9218f1bb0b4a5dd8d8141239b3211e1cd.zip
ref: Use storage instead of memory
With async search we can afford waiting a bit more it to load without making the ui sluggish.
Diffstat (limited to 'db')
-rw-r--r--db/db.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/db/db.go b/db/db.go
index c3699d7..24c2a31 100644
--- a/db/db.go
+++ b/db/db.go
@@ -57,7 +57,7 @@ func (d *DB) SelectDict(ctx context.Context, query string, limit int) ([]*Word,
`SELECT
word, line
FROM words
- WHERE word MATCH ?
+ WHERE words MATCH ?
ORDER BY rank
LIMIT ?;`,
query, limit,