Thank you for the very detailed post information. What you are experiencing is just a caching issue since you have installed Autoptimize plugin. After doing the updates and site changes, always remember to clear all caches (if you are using Autoptimize, WP Rocket, WP SuperCache or W3 Total Cache) when updating so that the code from the latest release is always in use. This will help you to avoid any potential errors.
Please clear your browser cache too. You may use private browsing mode in testing your site to make sure that you are viewing the latest codes from the updates and not the cached version in your browser.
And lastly, you are using CloudFlare. Please login to your CloudFlare account and purge your site cache as well.
Please let us know how it goes.