Critical error caused by filter
-
I previously had a query, regarding filtering -pdf.jpg files, that was resolved in this topic.
This lead to me adding the below code to the themes funtions.php
function my_custom_media_sync_additional_file_skip($is_ignored, $file) { $is_this_pdf_thumbnail = strpos($file->getFilename(), '-pdf.jpg') !== false; return $is_ignored || $is_this_pdf_thumbnail; } add_filter('media_sync_filter_is_scan_object_ignored', 'my_custom_media_sync_additional_file_skip', 10, 3);
This has been working fine for months, however this snippet seem so be causing an issue with the plugin: https://i.imgur.com/vHOS5hr.png
If I comment out the snippet the plugin appears to work fine, so I am assuming it is the snippet in functions.php that is causing the issue.
Is there anything I can change in the snippet to help resolve this issue?
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Critical error caused by filter’ is closed to new replies.