Category specific Patreon

Hi, Referring yo the code posted here

This works fine if you want all categories to be Patreon. Is there a way to make it only make Patreon a specific category like
if ( in_category( 511 ) ) { ?>

if ( !$user ) {

$user = wp_get_current_user();


Thanks for any pointers in advance

Definitely - just modify the code to check for that category as a condition in addition to existing conditions.

Or alternatively you can use Patron Pro to do category, tag, custom taxonomy locking.