keycdn / cache-enabler

A lightweight caching plugin for WordPress that makes your website faster by generating static HTML files.
https://wordpress.org/plugins/cache-enabler/
123 stars 46 forks source link

update getting settings #159

Closed coreykn closed 3 years ago

coreykn commented 3 years ago

Rename $skip_url_path variable to $skip_blog_path. Update getting the settings from the disk to create a settings file if the cache exists but the settings file does not. This means if there is no cache and no settings file the cached page will be delivered on the third request (instead of the second request if the settings file did exist):

  1. First request caches the page.

  2. Second request would try to get the settings from the disk and if not available will create it in the late engine start.

  3. Third request would deliver the cached page.

In most cases the settings file should always exist, but this will ensure a settings file is created if a page is being cached.