Created
February 12, 2015 01:02
-
-
Save barryhughes/bf5d020a6a8225664c09 to your computer and use it in GitHub Desktop.
Fixes a compatibility issue between WooCommerce 2.3.x and WooCommerce Tickets 3.9
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// ----------------------------------------------------------------------------- | |
// The code below this comment should be added to the theme's functions.php file | |
// ----------------------------------------------------------------------------- | |
// Compatibility fix to help run WooCommerce Tickets 3.9 with WooCommerce 2.3.x | |
if ( class_exists( 'TribeWooTickets' ) ) { | |
// Form reference to ticket processing callback | |
$wootickets = TribeWooTickets::get_instance(); | |
$callback = array( $wootickets, 'process_front_end_tickets_form' ); | |
// Switch to a later action | |
remove_action( 'init', $callback ); | |
add_action( 'wp_loaded', $callback ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment