• Resolved Benny

    (@bennygiesbers)


    We’ve seen two of our websites break recently, probably after some update. Not sure if it’s related to caching (we’re using WP Rocket + Cloudflare), but everything is pointing to Shortpixel Adaptive Images:

    ai.min.js:1 Uncaught TypeError: Cannot read property 'png' of undefined
        at SPAI.composeApiUrl (ai.min.js:1)
        at SPAI.updateSrc (ai.min.js:1)
        at SPAI.updateImageUrl (ai.min.js:1)
        at HTMLImageElement.<anonymous> (ai.min.js:1)
        at Function.each (jquery.js:2)
        at n.fn.init.each (jquery.js:2)
        at SPAI.handleUpdatedImageUrls (ai.min.js:1)
        at SPAI.handleBody (ai.min.js:1)
        at SPAI.setupIntersectionObserverAndParse (ai.min.js:1)
        at SPAI.init (ai.min.js:1)

    Is this a known issue? The plugin is currently deactivated so the issue is fixed.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Gerard Blanco

    (@sixaxis)

    Hi Benny,

    Probably this is related to caching. Could you pleas make sure to flush your cache following these instructions, try again and let me know if it works? https://help.shortpixel.com/article/426-how-to-clear-wordpress-cache

    Thanks,

    Thread Starter Benny

    (@bennygiesbers)

    Hi Gerard,

    Re-enabling the plugin and clearing the cache does fix the problem.
    But I’m far from convinced that it won’t come back. Can you clarify how caching can be the root cause of this problem, in a way that it’s not a bug?

    Plugin Support Gerard Blanco

    (@sixaxis)

    Hi Benny,

    Caching is something that “affects” all websites. As you probably know, there are multiples layers of cache: the browser, your cache plugins, your CDN, your host, sometimes even the ISP… So when a plugin is updated, sometimes old files from the plugin are cached somewhere and that creates conflicts between the new files and the old files.

    Unfortunately, with the information we have now it’s practically impossible to know what failed, or who cached what.

    Again, this is something that is not so common, but sometimes happens, and not only with our plugin, but with others as well (speaking from experience).

    Don’t worry, if clearing the cache fixes this, then you are all good.

    Have a good one!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Website breaking bug (JS error + no images)’ is closed to new replies.