WordPress.org

Make WordPress Core


Ignore:
Timestamp:
08/30/2012 01:33:00 PM (9 years ago)
Author:
ryan
Message:

Use set_url_scheme(). Props johnbillion, MarcusPope. see #19037 #20759

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/plugin.php

    r21291 r21664  
    904904    if ( empty($icon_url) )
    905905        $icon_url = esc_url( admin_url( 'images/generic.png' ) );
    906     elseif ( is_ssl() && 0 === strpos($icon_url, 'http://') )
    907         $icon_url = 'https://' . substr($icon_url, 7);
     906    else
     907        $icon_url = set_url_scheme( $icon_url );
    908908
    909909    $new_menu = array( $menu_title, $capability, $menu_slug, $page_title, 'menu-top ' . $hookname, $hookname, $icon_url );
Note: See TracChangeset for help on using the changeset viewer.