Open Pixelrobin opened 3 years ago
Came across this issue recently flooding my debug log when editing posts across our sites using this plugin. As a temporary solution, I have updated the yoast-acf-analysis.js refresh function to include the missing query parameter:
var refresh = function( attachment_ids ) {
var uncached = cache.getUncached( attachment_ids, "attachment" );
if ( uncached.length === 0 ) {
return;
}
window.wp.ajax.post( "query-attachments", {
query: {
post__in: uncached,
posts_per_page: 1
},
} ).done( function( attachments ) {
_.each( attachments, function( attachment ) {
cache.set( attachment.id, attachment, "attachment" );
window.YoastACFAnalysis.maybeRefresh();
} );
} );
};
i.e. posts_per_page: 1
in the post query around line ~122.
wp-content\plugins\acf-content-analysis-for-yoast-seo\js\yoast-acf-analysis.js
Hope this helps.
Please give us a description of what happened.
When editing a post that has an Image ACF field, the following PHP notices are thrown in the debug log:
Please describe what you expected to happen and why.
No PHP notices to be thrown.
How can we reproduce this behavior?
wp-config.php
with:debug.log
Technical info