Hey,
In order to show all of the available attributes upon landing on the ‘Add Listing’ page, I’d like to set a default category, instead of ‘—’.
I searched the forums and found an old post, but after trying the proposed snippet (below) it doesn’t seem to be working.
add_action(
'hivepress/v1/models/listing/create',
function($listing_id, $listing) {
$listing->set_categories(1)->save_categories();
},
1000,
2
);
If I can set a default category, I also like to hide the ‘—’
Cheers,
Chris