Re-enable the autoptimize plugin – and retest the site.
The issue may just have been the Javascripts got ‘cached’ incorrectly – sometimes all it takes is clearing the cache 🙂
If it still poses a problem then it will require further troubleshooting – but it won’t be a theme compatibility issue ( we use Autoptimize on our own site ) but one of the scripts the plugin is using.
As a note – when developing a site its best to leave cache/optimization plugins disabled.