Skip to content

Instantly share code, notes, and snippets.

@skyshab
Last active March 26, 2021 17:25
Show Gist options
  • Save skyshab/4d3e88ded02857607bd872d01165bfd2 to your computer and use it in GitHub Desktop.
Save skyshab/4d3e88ded02857607bd872d01165bfd2 to your computer and use it in GitHub Desktop.
Fix for shared capacity tickets available being wrong after deleting attendee
<?php
// Replace this value with the event id
$my_event_id = 123;
// Replace this value with the correct number of capacity
// that should be displaying for shared capacity tickets.
$correct_remaining_tickets = 9;
add_action( 'init', function() {
update_post_meta( $my_event_id, '_tribe_ticket_global_stock_level', $correct_remaining_tickets );
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment