Created
October 5, 2012 22:15
-
-
Save dancameron/3842763 to your computer and use it in GitHub Desktop.
GBS :: Filter submit_deal for non sponsors
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
add_action( 'submit_deal', 'redirect_non_sponsor_deal_submission' ); | |
function redirect_non_sponsor_deal_submission( Group_Buying_Deal $deal ) { | |
if ( is_user_logged_in() && !gb_account_has_merchant( get_current_user_id() ) ) { | |
$deal_id = $deal->get_ID(); | |
self::redirect_to_merch_registration( $deal_id ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment