I have my shop page set up to automatically display thumbnails linking to category pages. However, some of my categories only have one product in them, and it’d be great if those links went directly to the single product page rather than to a category page that then shows just one product.
woocommerce support told me I’d need to tweak content-product_cat.php (though how exactly to tweak it exceeds what they offer for support).
So I guess I’m looking for a conditional statement like “If only one product in category, create link to the single product page. If more than one product in category, create link to category page.”
Any ideas? Thanks in advance!