[wp-trac] [WordPress Trac] #28855: Commented add_actions and unused functions in wp-admin/includes/theme-install.php
WordPress Trac
noreply at wordpress.org
Sat Jul 12 16:59:43 UTC 2014
#28855: Commented add_actions and unused functions in wp-admin/includes/theme-
install.php
--------------------------+-----------------------------
Reporter: michalzuber | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: trunk
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
Only {{{install_themes_upload()}}} is used in`wp-admin/theme-
install.php:134`
{{{
mike at mike:~/Sites/wordpress-svn$ grep -r '// add_action' src/
src/wp-admin/includes/theme-install.php:135://
add_action('install_themes_dashboard', 'install_themes_dashboard');
src/wp-admin/includes/theme-install.php:147://
add_action('install_themes_upload', 'install_themes_upload', 10, 0);
src/wp-admin/includes/theme-install.php:179://
add_action('install_themes_search', 'display_themes');
src/wp-admin/includes/theme-install.php:180://
add_action('install_themes_featured', 'display_themes');
src/wp-admin/includes/theme-install.php:181://
add_action('install_themes_new', 'display_themes');
src/wp-admin/includes/theme-install.php:182://
add_action('install_themes_updated', 'display_themes');
mike at mike:~/Sites/wordpress-svn$ grep -r install_themes_dashboard src
src/wp-admin/includes/theme-install.php:96:function
install_themes_dashboard() {
src/wp-admin/includes/theme-install.php:135://
add_action('install_themes_dashboard', 'install_themes_dashboard');
mike at mike:~/Sites/wordpress-svn$ grep -r install_themes_upload src
src/wp-admin/includes/theme-install.php:137:function
install_themes_upload() {
src/wp-admin/includes/theme-install.php:147://
add_action('install_themes_upload', 'install_themes_upload', 10, 0);
src/wp-admin/theme-install.php:134: <?php install_themes_upload(); ?>
mike at mike:~/Sites/wordpress-svn$ grep -r install_themes_search src
src/wp-admin/includes/theme-install.php:179://
add_action('install_themes_search', 'display_themes');
mike at mike:~/Sites/wordpress-svn$ grep -r install_themes_featured src
src/wp-admin/includes/theme-install.php:180://
add_action('install_themes_featured', 'display_themes');
mike at mike:~/Sites/wordpress-svn$ grep -r install_themes_new src
src/wp-admin/includes/theme-install.php:181://
add_action('install_themes_new', 'display_themes');
mike at mike:~/Sites/wordpress-svn$ grep -r install_themes_updated src
src/wp-admin/includes/theme-install.php:182://
add_action('install_themes_updated', 'display_themes');
}}}
`display_themes` is used only in the same file `wp-admin/includes/theme-
install.php`, but in the commented add_actions. Should that function be
deprecated?
{{{
mike at mike:~/Sites/wordpress-svn$ grep -r display_themes src
src/wp-admin/includes/theme-install.php:122:function display_themes() {
src/wp-admin/includes/theme-install.php:132://
add_action('install_themes_search', 'display_themes');
src/wp-admin/includes/theme-install.php:133://
add_action('install_themes_featured', 'display_themes');
src/wp-admin/includes/theme-install.php:134://
add_action('install_themes_new', 'display_themes');
src/wp-admin/includes/theme-install.php:135://
add_action('install_themes_updated', 'display_themes');
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/28855>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list