mirror of
https://github.com/nagaoo0/HabbitGrid.git
synced 2026-01-11 23:44:55 +00:00
Update drag and drop update and sync to db
This commit is contained in:
@@ -134,6 +134,8 @@ export async function updateHabit(id, updates) {
|
||||
console.warn('Supabase updateHabit error, writing local:', error.message);
|
||||
return local.updateHabit(id, updates);
|
||||
}
|
||||
// After any update, trigger a sync to ensure all local changes (including categories) are pushed to remote
|
||||
await syncLocalToRemoteIfNeeded();
|
||||
}
|
||||
|
||||
export async function deleteHabit(id) {
|
||||
|
||||
Reference in New Issue
Block a user