wrap isar.clear() in isar.writeTxn() to avoid error

This commit is contained in:
ashilkn 2024-01-20 15:39:44 +05:30
parent c981a311cf
commit 8259587d45

View file

@ -23,7 +23,7 @@ class EmbeddingsDB {
}
Future<void> clearTable() async {
await _isar.clear();
await _isar.writeTxn(() => _isar.clear());
}
Future<List<Embedding>> getAll(Model model) async {