From 029e5db6a8dea100620cb80f4f397cf103e59f85 Mon Sep 17 00:00:00 2001 From: Trevor Buckner Date: Wed, 7 Oct 2026 16:33:47 +0000 Subject: [PATCH] Need to snapshot brew before save without hash/patch metadata --- client/homebrew/utils/commonEditPageFunctions.jsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/client/homebrew/utils/commonEditPageFunctions.jsx b/client/homebrew/utils/commonEditPageFunctions.jsx index f379b9c2b..48048c619 100644 --- a/client/homebrew/utils/commonEditPageFunctions.jsx +++ b/client/homebrew/utils/commonEditPageFunctions.jsx @@ -206,6 +206,7 @@ export default function useCommonEditPageFunctions(dependencies) { setHTMLErrors(hbfm.validate(currentBrew.text)); //Prepare content to send to server + const snapshotBrewBeforeSave = currentBrew; const brewToSave = { ...currentBrew, text : currentBrew.text.normalize('NFC'), @@ -220,7 +221,7 @@ export default function useCommonEditPageFunctions(dependencies) { .catch((err)=>{setError(err);}); if(savedBrew) { lastSavedBrew.current = { - ...brewToSave, + ...snapshotBrewBeforeSave, ...savedBrew };