After waiting for 2 years on Divi to fix the bug, Autoptimize as from the next release will not allow it to incorrectly clear the AO cache any more.
Fixing “Edit with Elementor” and Autoptimize
A regularly reported issue for Autoptimize + Elementor users is that JavaScript optimization breaks the “Edit with Elementor” button in the front-end admin bar. The easiest workaround is to disable the “also optimize for logged in administrators/ editors” option, but below code snippet is more surgical as it will only disable JS optimization, leaving e.g. CSS & Image, which do not impact “Edit with Elementor”, active;
if ( defined( 'ELEMENTOR_VERSION' ) && is_user_logged_in() && current_user_can( 'edit_posts' ) ) {
add_filter( 'autoptimize_filter_js_noptimize', '__return_true' );
}
When in doubt, you can use the code snippets plugin to safely add this.
Of bugs and workarounds vs. root cause
My father, a retired mechanical engineer and a who’s technical skills, knowledge and passion are a big inspiration for me, always told his colleagues never to quick-fix the problem, but to look for the root cause instead.
This obviously is true for software as well and remembering this good advice while walking the dogs yesterday evening stopped me from committing a finished workaround for a small bug (notices in the PHP error-log) and got me frantically error-logging left and right to try to identify the root of the problem this morning.
That root cause, as it turned out, was just a misplaced closing round bracket resulting in a combined conditional not executing correctly (I admit something silly like that should have been spotted during testing). Once identified, the fix was easily applied, improving the code and preventing extra workaround code from making things more complex.
So again: thanks dad!
Fitbit zegt: frieten eten is ook een sport
Gisterenavond hebben we ons nog eens op friet van het frietkot gesmeten en tijdens die schranspartij trilde mijn Fitbit goedkeurend. Op het einde van de rit rekende mijn niet-toch-niet-zo-slim horloge me voor dat ik gedurende 36 minuten vet had verbrand en zo 285 caloriën had verbruikt. Goed toch?
Music from Our Tube: Naima Joris – Bloom (Radiohead)
This is how I “Bloom”…in mourning mode. Again. And again. And again. And again. And again. And again. Guess what keeps me alive…
Naima Joris, Facebook
This is not just a cover of a beautiful song (which I consider one of the best ever by Radiohead), this is so full of emotion, so real, so painful. Naima Joris is a great artist!
The Healing Force from Our Tube: Emanative
When I heard this on PBB (I think, but it might have been WorldWide FM as well) I thought it was a nice hat tip to spiritual jazz of the sixties & seventies, but it turns out it’s a cover/ remake of a tune that was originally performed by saxophonist Albert Ayler (mostly known as free-jazz saxophonist and protégé of John Coltrane) and written (and sung) by his partner Mary Maria Parks back in 1969.
Gelezen: Norwegian Wood van Haruki Murakami
Prachtige roman over geestelijk gewonde mensen, fundamentele eenzaamheid en pogingen daaraan te ontsnappen. Maar vrolijk word je er niet van …
Music from our Tube: Aimee Mann – I see You
Over 20 years have passed since first seeing Magnolia which not only was a beautiful movie, but also a testament to the great songwriter Aimee Mann is. “I see You” is a song from her new album “Queens of the Summer Hotel” and it is just as great!
Music from Our Tube: Joan As Police Woman & Tony Allen & Dave Okumu’s Geometry of You
Just when I was starting to get a good old-fashioned cold I heard this on the radio while in the car. It didn’t stop me from going into hibernation for a couple of days, but man what a great tune!