Plugin Directory

Changeset 1609668


Ignore:
Timestamp:
03/07/2017 11:01:27 AM (9 years ago)
Author:
wherd
Message:

Fix bug on tiny_mce_plugins filter and load textdomain

Location:
disable-emojis-polyfill/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • disable-emojis-polyfill/trunk/disable-emojis-polyfill.php

    r1608681 r1609668  
    1212 * Plugin URI:  https://wordpress.org/plugins/disable-emojis-polyfill/
    1313 * Description: Disable WordPress Emojis backwards compatibility.
    14  * Version:     1.0.0
     14 * Version:     1.0.1
    1515 * Author:      Sérgio 'wherd' Leal
    1616 * License:     GPL2
     
    4141     *
    4242     * @since 1.0.0
     43     * @since 1.0.1 - load textdoamin
    4344     *
    4445     * @see https://core.trac.wordpress.org/browser/tags/4.7/src/wp-includes/default-filters.php
    4546     */
    4647    function wd_disable_emojis() {
     48        // Load plugin textdomain.
     49        load_plugin_textdomain( 'disable-emojis-polyfill', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );
     50
    4751        // Disable from printing the inline Emoji detection style and script.
    4852        remove_action( 'wp_print_styles', 'print_emoji_styles' );
     
    7478     *
    7579     * @since 1.0.0
     80     * @since 1.0.1 - fix variable name typo
    7681     *
    7782     * @see https://developer.wordpress.org/reference/hooks/tiny_mce_plugins/
     
    8186     */
    8287    function wd_disable_emojis_tinymce( $plugins ) {
    83         return is_array( $plugins ) ? array_diff( $result, array( 'wpemoji' ) ) : $plugins;
     88        return is_array( $plugins ) ? array_diff( $plugins, array( 'wpemoji' ) ) : $plugins;
    8489    }
    8590endif;
  • disable-emojis-polyfill/trunk/readme.txt

    r1609606 r1609668  
    55Requires at least: 4.6
    66Tested up to: 4.7
    7 Stable tag: 1.0.0
     7Stable tag: 1.0.1
    88License: GPLv2 or later
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html
     
    3535* Initial release.
    3636
     37= 1.0.1 =
     38* Fix bug on `tiny_mce_plugins` filter
     39* Load textdomain
     40
    3741== Frequently Asked Questions ==
    3842
Note: See TracChangeset for help on using the changeset viewer.