WordPress.org

Making WordPress.org

Changeset 1663


Ignore:
Timestamp:
06/16/2015 02:13:02 PM (5 years ago)
Author:
iandunn
Message:

Jetpack Tweaks: Consolidate our Jetpack tweaks into a single mu-plugin.

See #1073

Location:
sites/trunk/wordcamp.org/public_html/wp-content/mu-plugins
Files:
1 edited
1 moved

Legend:

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

    r1653 r1663  
    11<?php
    2 /*
    3  * Plugin Name: Jetpack Publicize Tweaks
    4  * Description: Tweak the way that posts shared on social media services will be displayed
    5  * Version:     0.1
    6  * Author:      Brandon Kraft
    7  */
    8 
    92
    103/*
     
    4740}
    4841add_filter( 'jetpack_twitter_cards_site_tag', 'wc_twitter_sitetag' );
     42
     43/*
     44 * Determine which Jetpack modules should be automatically activated when new sites are created
     45 */
     46function wcorg_default_jetpack_modules( $modules ) {
     47    $modules = array_diff( $modules, array( 'widget-visibility' ) );
     48    array_push( $modules, 'contact-form', 'shortcodes', 'custom-css', 'subscriptions' );
     49
     50    return $modules;
     51}
     52add_filter( 'jetpack_get_default_modules', 'wcorg_default_jetpack_modules' );
  • sites/trunk/wordcamp.org/public_html/wp-content/mu-plugins/wcorg-misc.php

    r1514 r1663  
    2121}
    2222add_filter( 'close_comments_for_post_types', 'wcorg_close_comments_for_post_types' );
    23 
    24 /*
    25  * Determine which Jetpack modules should be automatically activated when new sites are created
    26  */
    27 function wcorg_default_jetpack_modules( $modules ) {
    28     $modules = array_diff( $modules, array( 'widget-visibility' ) );
    29     array_push( $modules, 'contact-form', 'shortcodes', 'custom-css', 'subscriptions' );
    30 
    31     return $modules;
    32 }
    33 add_filter( 'jetpack_get_default_modules', 'wcorg_default_jetpack_modules' );
    3423
    3524/*
Note: See TracChangeset for help on using the changeset viewer.