Always exit after wp_redirect. props filosofo, fixes #15518.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16847 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -178,13 +178,17 @@ if ( isset($plugin_page) ) {
|
||||
if ( ! current_user_can('import') )
|
||||
wp_die(__('You are not allowed to import.'));
|
||||
|
||||
if ( validate_file($importer) )
|
||||
if ( validate_file($importer) ) {
|
||||
wp_redirect( admin_url( 'import.php?invalid=' . $importer ) );
|
||||
exit;
|
||||
}
|
||||
|
||||
// Allow plugins to define importers as well
|
||||
if ( !isset($wp_importers) || !isset($wp_importers[$importer]) || ! is_callable($wp_importers[$importer][2])) {
|
||||
if (! file_exists(ABSPATH . "wp-admin/import/$importer.php"))
|
||||
if (! file_exists(ABSPATH . "wp-admin/import/$importer.php")) {
|
||||
wp_redirect( admin_url( 'import.php?invalid=' . $importer ) );
|
||||
exit;
|
||||
}
|
||||
include(ABSPATH . "wp-admin/import/$importer.php");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user