Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion lib/src/database/sqflite_box.dart
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ class BoxCollection with ZoneTransactionMixin {
batch.execute(
'CREATE TABLE IF NOT EXISTS $name (k TEXT PRIMARY KEY NOT NULL, v TEXT)',
);
batch.execute('CREATE INDEX IF NOT EXISTS k_index ON $name (k)');
batch.execute(
'DROP INDEX IF EXISTS k_index',
); // Previously we have created a redundant index. We can safely remove it.
Comment thread
krille-chan marked this conversation as resolved.
}
await batch.commit(noResult: true);
return BoxCollection(sqfliteDatabase, boxNames, name);
Expand Down
Loading