feat: Update category deletion logic to reset related notes and track changes
This commit is contained in:
@@ -87,6 +87,11 @@ class NoteRepository {
|
||||
|
||||
Future<void> deleteCategory(String id) async {
|
||||
await _database.deleteCategory(id);
|
||||
|
||||
await _database.customStatement(
|
||||
'UPDATE notes SET category_id = NULL, is_dirty = 1 WHERE category_id = ?',
|
||||
[id],
|
||||
);
|
||||
}
|
||||
|
||||
Future<Note> createNote(Note note) async {
|
||||
|
||||
Reference in New Issue
Block a user