From ab7ca361ddebcd4dab6cb9b31b5bc887a3e34712 Mon Sep 17 00:00:00 2001 From: Scott Taylor Date: Mon, 14 Sep 2015 20:28:29 +0000 Subject: [PATCH] In `WP_List_Table`, make a new `public` method, `->get_primary_column()`, and revert [34101] due to BC issues. Fixes #33854. git-svn-id: https://develop.svn.wordpress.org/trunk@34128 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-list-table.php | 6 +++++- src/wp-admin/includes/class-wp-ms-themes-list-table.php | 2 +- src/wp-admin/includes/class-wp-plugins-list-table.php | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/includes/class-wp-list-table.php b/src/wp-admin/includes/class-wp-list-table.php index 105efbe202..69e357b1d0 100644 --- a/src/wp-admin/includes/class-wp-list-table.php +++ b/src/wp-admin/includes/class-wp-list-table.php @@ -888,6 +888,10 @@ class WP_List_Table { return $column; } + public function get_primary_column() { + return $this->get_primary_column_name(); + } + /** * Gets the name of the primary column. * @@ -896,7 +900,7 @@ class WP_List_Table { * * @return string The name of the primary column. */ - public function get_primary_column_name() { + protected function get_primary_column_name() { $columns = $this->get_columns(); $default = $this->get_default_primary_column_name(); diff --git a/src/wp-admin/includes/class-wp-ms-themes-list-table.php b/src/wp-admin/includes/class-wp-ms-themes-list-table.php index 907bad785f..991a07749a 100644 --- a/src/wp-admin/includes/class-wp-ms-themes-list-table.php +++ b/src/wp-admin/includes/class-wp-ms-themes-list-table.php @@ -252,7 +252,7 @@ class WP_MS_Themes_List_Table extends WP_List_Table { * * @return string Unalterable name of the primary column name, in this case, 'name'. */ - public function get_primary_column_name() { + protected function get_primary_column_name() { return 'name'; } diff --git a/src/wp-admin/includes/class-wp-plugins-list-table.php b/src/wp-admin/includes/class-wp-plugins-list-table.php index 31d0e2e302..781330cbdf 100644 --- a/src/wp-admin/includes/class-wp-plugins-list-table.php +++ b/src/wp-admin/includes/class-wp-plugins-list-table.php @@ -724,7 +724,7 @@ class WP_Plugins_List_Table extends WP_List_Table { * * @return string Unalterable name for the primary column, in this case, 'name'. */ - public function get_primary_column_name() { + protected function get_primary_column_name() { return 'name'; } }