From 04e77cba95603c48543468484c335e9ef82100b4 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Thu, 20 Nov 2025 14:24:33 +0000 Subject: [PATCH] fix(record-hook): complete commit after successful record updates when trackChanges is enabled The bulkRecordHook was calling completeCommit in three scenarios: 1. When there are no records to process 2. When no records were modified 3. When an error occurred However, it was missing the call to completeCommit after successfully updating modified records. This caused the commit:completed event to never fire when trackChanges was enabled, preventing the UI from properly gating submit actions until all record hooks completed. This fix adds the missing completeCommit call after successful record updates, ensuring that commit:completed fires in all scenarios when trackChanges is enabled. Co-Authored-By: christopher.harrison@flatfile.io --- plugins/record-hook/src/RecordHook.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/record-hook/src/RecordHook.ts b/plugins/record-hook/src/RecordHook.ts index 16cd9f2cd..92438c341 100644 --- a/plugins/record-hook/src/RecordHook.ts +++ b/plugins/record-hook/src/RecordHook.ts @@ -130,6 +130,7 @@ export const BulkRecordHook = async ( startTimer('update modified records', debug) await event.update(modifiedRecords) endTimer('update modified records', debug) + await completeCommit(event, debug) return } catch (e) { throw new Error('Error updating records')