@pfefferle Whatever you do: Do not (only) rely on hooks that only trigger when using the standard, internal updating mechanism like https://developer.wordpress.org/reference/hooks/upgrader_process_complete/
There are way too many sites out there that update differently (manual, FTP, composer etc.)
Generally I'd say have an autoloaded option that stores the current version you compare with the current version. On mismatch start migration.
Also be careful to handle downgrades or other broken states and not solely rely on version info in the option
Embed Notice
HTML Code
Corresponding Notice
- Embed this notice
Thomas Kräftner (kraftner@mastodon.social)'s status on Tuesday, 05-Mar-2024 18:34:54 JSTThomas Kräftner