Wordpress LScache Plugin: Social Warfare plugin
Last Updated on: Wed, 15 Apr 2026 00:00:02 Ive run into a problem with the Social Warfare plugin as follows: When I combine all my javascript files Social Warfare doesnt seem to update the social share counts. When Ive checked the web inspector in reports the following (Ive replaced the angle brackets with square brackets): [script type= text/javascript ] swpPinIt= enabled :false var swpClickTracking = false var swp_nonce = ff96d25db7 var swp_buttons_exist = document.getElementsByClassName( nc_socialPanel ) if ( swp_buttons_exist ) swp_admin_ajax = https://chromasia.com/wp/wp-admin/admin-ajax.php’ swp_post_id=9064 swp_post_url=https://chromasia.com/buzludzha-2-2017/’ swp_post_recovery_url = socialWarfarePlugin.fetchShares() [/script] The line socialWarfarePlugin.fetchShares() generates this error: Cant find variable: socialWarfarePlugin The net result is that Social Warfare doesnt update the share counts unless I disable JS Combine. Ive also tried excluding Social Warfare from being combined, along with jquery and pretty much every other script I can find, but as long as JS Combine is enabled the share counts dont update. As soon as I turn off JS Combine everything goes back to normal. Im hoping you can fix this as JS Combine makes a significant improvement to my page speed scores but I just cant get it to work with Social Warfare. The page I need help with: https://chromasia.com/ Noted. Will check the compatibility with Social Warfare plugin. Thanks for your feedback. Youre welcome. Will you update here if you find anything? Yes we will. Excellent. Thanks. Ive done some further checking. The code I included above is generated when Social Warfare is set to Legacy Caching. When set to Advance Cache Triggering no errors are generated but the share counts still fail to update. Best wishes, Dave Hi there, I wondered if youd manage to identify if theres a problem with the Social Warfare plugin and Litespeed? Theres no rush, its just that Im still trying to troubleshoot this issue on my own site. Best wishes, Dave Hi, @chromasia Afraid not. We havent had a chance to explore it yet, but its on the list! Sorry for the wait. Were putting the finishing touches on our next update. Hi Lisa, No problem, Im just keen to get it resolved as in all other respects its working flawlessly. Ill wait for your next update. Best wishes, Dave Ive done some further testing. Social Warfare works if you disable JS Minify and JS HTTP/2 Push. I noticed you put socialWarfarePlugin into a jquery document ready wrapper, which should fix the issue. Am I right? The socialWarfarePlugins lib script is in footer js. So what you have done is the ideal way to fix it. That wasnt anything I did, and I still dont think its working properly with JS Minify, but it seems to be working OK at the moment. However, there is a potential nonce bug once it gets cached. I created a pull request to the authors repo: https://github.com/warfare-plugins/social-warfare/pull/421 If you meet any more issue, please create a new topic to let us know. Thanks. Excellent. I cant pretend I understand the last bit, but it definitely sounds like youve got the problem in hand. Thanks.
LiteCache Rush: Speed comes from using less, not from doing it faster
Reference