WordPress.org

Making WordPress.org

Ticket #3493: 3493.2.diff

File 3493.2.diff, 2.0 KB (added by hlashbrooke, 2 years ago)

Removing unneeded function

  • wordcamp.org/public_html/wp-content/mu-plugins/camptix-tweaks/camptix-tweaks.php

    diff --git wordcamp.org/public_html/wp-content/mu-plugins/camptix-tweaks/camptix-tweaks.php wordcamp.org/public_html/wp-content/mu-plugins/camptix-tweaks/camptix-tweaks.php
    index 1617b0f..6fa7762 100644
    add_filter( 'camptix_capabilities', __NAMESPACE__ . '\modify_capabilities' 
    3232add_filter( 'camptix_default_options', __NAMESPACE__ . '\modify_default_options'    );
    3333add_filter( 'camptix_html_message',    __NAMESPACE__ . '\render_html_emails', 10, 2 );
    3434add_action( 'camptix_tshirt_report_intro', __NAMESPACE__ . '\tshirt_report_intro_message', 10, 3 );
     35add_filter( 'camptix_hide_empty_tickets', '__return_false' );
    3536
    3637
    3738/**
    function stripe_credentials( $credentials ) { 
    155156        return $credentials;
    156157}
    157158
    158 /*
    159  * Show empty tickets
    160  *
    161  * This provides a way for individual WordCamps to decide if they want to show sold-out tickets in the [tickets]
    162  * shortcode output. This can help avoid confusion if the camp has several types of tickets (e.g., General
    163  * Admission, Micro-sponsorship, etc) and the General Admission ticket sells out. If the General Admission ticket
    164  * was hidden, some users may mistakenly think that the Micro-sponsorship ticket is the "normal" ticket, even
    165  * though it costs several hundred dollars. Since we value keeping regular tickets accessible by as many people
    166  * as possible, we don't want anyone getting the impression that WordCamps are expensive to attend.
    167  *
    168  * @todo change this to use feature-flags similar to the skip-feature flags
    169  */
    170 function hide_empty_tickets() {
    171         $targeted_wordcamps_ids = array(
    172                 299, // San Francisco 2013
    173                 364, // San Francisco 2014
    174         );
    175 
    176         if ( in_array( get_current_blog_id(), $targeted_wordcamps_ids ) ) {
    177                 add_filter( 'camptix_hide_empty_tickets', '__return_false' );
    178         }
    179 }
    180 
    181159/**
    182160 * Enqueue the login message styles on the tickets screen.
    183161 */