Improve unseen cursor movement performance

It's only really noticeable when pressing H at the first unseen message
This commit is contained in:
Joscha 2022-08-08 17:24:44 +02:00
parent bfc221106d
commit 0490ce394d

View file

@ -85,7 +85,10 @@ fn m2(tx: &mut Transaction<'_>) -> rusqlite::Result<()> {
tx.execute_batch(
"
ALTER TABLE euph_msgs
ADD COLUMN seen INTEGER NOT NULL DEFAULT TRUE
ADD COLUMN seen INTEGER NOT NULL DEFAULT TRUE;
CREATE INDEX euph_idx_msgs_room_id_seen
ON euph_msgs (room, id, seen);
",
)
}