I have installed Schema Pro and got three results in Google Structured Data Testing Tool for all my Products. Their tech support told me that one result was from WooCommerce and they gave me code to disable it.
By switching themes the issue was fixed, so we assume the extra one is coming from my child theme. From previous forum posts I saw that the solution is to add
add_filter( 'generate_schema_type', '__return_false' );
to my functions.php
Seemed simple and I was elated, except that it doesn’t work. I’ve tried adding it to my functions.php, and when that didn’t work I tried adding it as a snippet in Woody Ad Snippets. No change. I am still showing two results for all the Products in my store.
I’ve deactivated my caching plugin, dumped my history and tried it in different browsers. The issue remains.
What am I missing? Thank you.