Making WordPress.org

Changeset 6708


Ignore:
Timestamp:
02/21/2018 07:30:44 PM (5 years ago)
Author:
coreymckrill
Message:

WordCamp: Avoid errors when dev environment doesn't have Stripe creds defined

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordcamp.org/public_html/wp-content/mu-plugins/wcorg-misc.php

    r6707 r6708  
    278278        case 'development':
    279279        default :
    280             $options['publishable'] = WORDCAMP_PAYMENT_STRIPE_PUBLISHABLE;
    281             $options['secret']      = WORDCAMP_PAYMENT_STRIPE_SECRET;
     280            $options['publishable'] = ( defined( 'WORDCAMP_PAYMENT_STRIPE_PUBLISHABLE' ) ) ? WORDCAMP_PAYMENT_STRIPE_PUBLISHABLE : '';
     281            $options['secret']      = ( defined( 'WORDCAMP_PAYMENT_STRIPE_SECRET' ) ) ? WORDCAMP_PAYMENT_STRIPE_SECRET : '';
    282282            break;
    283283    }
    284284
    285     $options['hmac_key'] = WORDCAMP_PAYMENT_STRIPE_HMAC;
     285    $options['hmac_key'] = ( defined( 'WORDCAMP_PAYMENT_STRIPE_HMAC' ) ) ? WORDCAMP_PAYMENT_STRIPE_HMAC : '';
    286286
    287287    return $options;
Note: See TracChangeset for help on using the changeset viewer.