You click the Update button for themes, and then remember you have customizations in functions.php. Help! Defender!…
What if Defender saves your active them functions.php every day? You update and overwrite the file. Defender offers you the original and a diff view so that you can put your changes back in.
Or, just get the daily snapshot and don’t worry about diffs and editing.
Or, don’t get daily snapshots. After a theme update, get a snapshot of functions.php. If you click to Update the theme, just before the update, defender checks to see if the current file is different from the original, and it gets a new save right there. Now, right after you wipe away the tears for your lost functions, you can get Defender to show you the before and after files, maybe with a diff, and maybe the new file, with a three-way diff … OK, that’s pushing it.
This functionality would save a site from needing to recover the one file from other backup/snapshots, which can be somewhat painful depending on how they’re done – or IF they’re done.
(No, this hasn’t happened to me yet, but anytime I or someone does an update, or there is an auto-update, I choke a bit, wondering if we put anything in functions.php just as a quick fix/test.)