Support » Plugin: Autoptimize » Current update broke empty cache

  • Resolved designdrumm

    (@designdrumm)



    Hi Guys,
    Your current update seems to have broken the empty cache setting for the plugin. I tested the new update and it wouldn’t clear the cache. I delete it and installed the previous version and it worked as expected.

    May want to take a look at it. I will wait for the next update to see if it is fixed before using.

    Great plugin, thank you!

    Best,
    designdrumm

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Author Optimizing Matters

    (@optimizingmatters)

    no, that’s expected behavior @designdrumm; AO clears the cache and immediately does some preloading, cfr. FAQ πŸ™‚

    @optimizingmatters
    How do we know it cleared? There is no indication that it does like before. Before if cleared, it would say 0. Now your saying that it immediately preloads the cache, but that would be for one person, Me, after a clear and I clearly do not have that many files that it would fill back up to the same amount of space used.

    Are you using the same cache files for every user that comes to the site?

    Best,
    designdrumm

    Just saw your FAQ link. Read your reasons for the cache issue.
    Personally, I do not like this behavior as it breaks from what was working in the first place. Not sure why you changed it, but I do not want that.

    I will stick with the prior version for now until I find a different plugin.
    It worked better on my site the way you had it.

    Best,
    designdrumm

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    well, you can do 3 things;
    1. find another plugin
    2. download & use version 2.1.2 which does not do cache preloading (it’s functionally identical to 2.1.0 but has an important security fix)
    3. use 2.2.2 with this code snippet to disable the “speedupper” (which includes the cache preload);

    add_filter('autoptimize_filter_speedupper','__return_false');

    I’d go with (3) if I were you πŸ˜‰

    Have fun,
    frank

    Thank you @optimizingmatters,
    That sounds like a worthy suggestion. I truly do not want to go find another plugin, I enjoy this one very much. It and a few others combined help me take a website with a 17/100 page speed score to a 100/100, so it would be a shame to have to root that up and find another one.

    I think I will go with #3 as well…
    Where to implement so I don’t have to ever update?

    Thank you for the quick replies as well.
    A++ support!

    Best,
    designdrumm

    Just rated 5 stars! Thank you for your efforts!

    Best,
    designdrumm

    Hey @optimizingmatters,
    I noticed you load true by default. Is there a chance you could put a checkbox to turn on/off preload? That seems to be the best solution, otherwise I am building a plugin that will load your script you posted.

    Would be nice if there was a checkbox in the plugin though.
    Much easier and less over-head IMO. πŸ™‚

    Best,
    designdrumm

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    the easiest (safest) way to add that snippet would be the code snippet plugin @designdrumm.

    regarding checkbox; too many options already, trying to keep things lite for “normal users” and offer additional features/ options for “power users” in the API πŸ™‚

    thanks for the great review! πŸ™‚

    Hmmm, I don’t see how a single checkbox could be confusing to “normal users”. WC3 offers a checkbox for this same thing in their free version. I would consider this functionality something a user should have control over, even at base skill level.

    No worries though. I have found my solution.
    I just commented out lines 156-158 inside autoptimize.php.

    Not only does it fix my problem, but now there is one less file being loaded.

    Best,
    designdrumm

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    I don’t see how a single checkbox could be confusing to β€œnormal users”.

    well, for every filter I have almost every time someone asks to make that an option. considering I have lot of filters, that would make for a lot of extra options, but I want to avoid option-overload, so … πŸ™‚

    I just commented out lines 156-158 inside autoptimize.php. Not only does it fix my problem, but now there is one less file being loaded.

    that will obviously work, but do keep in mind you would have to re-apply that after every AO-update. adding the filter I mentioned earlier (using the code snippets plugin or adding it to your child theme’s functions.php) has the identical impact and does not require anything after an update πŸ™‚

    frank

    I understand your stance and I don’t mean to be pushy. What I am speaking of is just a checkbox asking if we want to prime the cache after empty.

    You already have the functionality set up to be loaded on a boolean anyway, so adding code to check for a wp-option that was set by this checkbox seems pretty lite for an added option. I personally do not really like to use child themes. I have my ways of modifying a theme or plugin without having to update every update. However, every once and a while I run into this situation and for me it’s not too complex to make the changes myself.

    As far as the code snippet you supplied, it did not work for me. I created a plugin that would load it, still nothing, and so that is when I found my solution. Personally, I would rather not add more plugins to the load list for something another plugin is doing. That seems wasteful regarding bandwidth and load times. So for me if I have to edit someones theme or plugin to get the results I want, well then that is what I have to do. Besides, “find and replace” is a magical thing. πŸ˜‰

    Side note: I always wondered why WP doesn’t have a file comparison for theme and plugin updates. When an update comes through, a script reads it and modifies what has been changed and if there is any code that is not in the original or the update, just leave it because it’s most likely a user edit. I’m sure that the developers of WP could give example how this idea has a swiss cheese appeal, but I think WP is advanced enough to tackle this functionality and improve their CMS by eliminating the need for child themes and give developers more freedom to edit. Just a thought anyways.

    Thanks for your replies. I will see if I can get that snippet to work, but other than putting it inside your plugin (I do not have a child theme for this website), I am not sure what to hook onto from your plugin. That may be why my plugin didn’t work.

    Best Regards,
    designdrumm

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    As far as the code snippet you supplied, it did not work for me. I created a plugin that would load it, still nothing

    feel free to share the code on pastebin.com or gists.github.com and i’ll have a look πŸ™‚

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Current update broke empty cache’ is closed to new replies.