Remove dead code from the Links widget. Props pavelevap, SergeyBiryukov. Fixes #19179.

The widget() method isn't called on the admin screen.


git-svn-id: https://develop.svn.wordpress.org/trunk@20245 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jon Cave 2012-03-21 21:01:05 +00:00
parent 88482603e4
commit 9c5f3d0243

View File

@ -106,12 +106,6 @@ class WP_Widget_Links extends WP_Widget {
$order = $orderby == 'rating' ? 'DESC' : 'ASC';
$limit = isset( $instance['limit'] ) ? $instance['limit'] : -1;
if ( is_admin() && !$category ) {
// Display All Links widget as such in the widgets screen
echo $before_widget . $before_title . _x('All Links', 'links widget') . $after_title . $after_widget;
return;
}
$before_widget = preg_replace('/id="[^"]*"/','id="%id"', $before_widget);
wp_list_bookmarks(apply_filters('widget_links_args', array(
'title_before' => $before_title, 'title_after' => $after_title,