Plugin Directory

Changeset 2054019


Ignore:
Timestamp:
03/20/2019 01:51:44 PM (7 years ago)
Author:
augustinfotech
Message:

Bug Fixes For Deprecated Function

Location:
woocommerce-menu-extension
Files:
11 added
2 edited

Legend:

Unmodified
Added
Removed
  • woocommerce-menu-extension/trunk/readme.txt

    r2025976 r2054019  
    44Requires at least: 3.0
    55Tested up to: 5.0.3
    6 Stable tag: 1.6.1
     6Stable tag: 1.6.2
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    8080== Changelog ==
    8181
     82= 1.6.2 =
     83* Bug Fixes For Deprecated Function.
     84
    8285= 1.6.1 =
    8386* Hot fixes.
  • woocommerce-menu-extension/trunk/woocommerce-menu-extension.php

    r2025976 r2054019  
    44Plugin URI: http://www.augustinfotech.com
    55Description: You can now add woocommerce links in your WP menus.
    6 Version: 1.6.1
     6Version: 1.6.2
    77Text Domain: woocommerce-menu-extension
    88Author: August Infotech
     
    1010*/
    1111
    12 define( 'AIWOO_VERSION', '1.6.1' );
     12define( 'AIWOO_VERSION', '1.6.2' );
    1313
    1414include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
     
    1717
    1818if ( is_plugin_active( 'woocommerce/woocommerce.php' ) ) {
    19 
    20     add_action( 'plugins_loaded', create_function( '', '
    21             $filename  = "include/";
    22             $filename .= is_admin() ? "backend.inc.php" : "frontend.inc.php";
    23             if( file_exists( plugin_dir_path( __FILE__ ) . $filename ) )
    24                 include( plugin_dir_path( __FILE__ ) . $filename );
    25         '   )
    26     );
    27        
     19        add_action( 'plugins_loaded', 'aiwoo_plugin_include', 10, 1);
     20   
    2821        // edit menu walker
    2922        add_filter( 'wp_edit_nav_menu_walker', 'aiwoo_edit_walker', 10, 2 );
     
    3932} else {
    4033    add_action('admin_notices', 'aiwoo_plugin_admin_notices');
     34}
     35
     36function aiwoo_plugin_include(){
     37    $filename  = "include/";
     38    $filename .= is_admin() ? "backend.inc.php" : "frontend.inc.php";
     39    if( file_exists( plugin_dir_path( __FILE__ ) . $filename ) )
     40        include( plugin_dir_path( __FILE__ ) . $filename );
    4141}
    4242
Note: See TracChangeset for help on using the changeset viewer.