Check if any users are logged in before running update

Because of the stateless nature of webpages, you can’t do this without a high margin of error.

You can install a plugin to log last visits for logged in users, but that will not tell you if they’re editing posts or if they loaded a page then went to lunch or shut down their computer.

Instead, use maintenance mode and arrange beforehand when to update the site. Anybody who wants to make edits or modifications at those times knows theres a chance it will be lost and they do so at their own risk.

Leave a Comment