Make sure plugin is a file before loading. Props filosofo. fixes #5822
git-svn-id: https://develop.svn.wordpress.org/trunk@6897 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
5e246a6c45
commit
9b7fadbb2f
@ -53,7 +53,7 @@ if (isset($plugin_page)) {
|
||||
wp_die(__('Invalid plugin page'));
|
||||
}
|
||||
|
||||
if (! file_exists(ABSPATH . PLUGINDIR . "/$plugin_page"))
|
||||
if (! ( file_exists(ABSPATH . PLUGINDIR . "/$plugin_page") && is_file( ABSPATH . PLUGINDIR . "/$plugin_page") ) )
|
||||
wp_die(sprintf(__('Cannot load %s.'), htmlentities($plugin_page)));
|
||||
|
||||
do_action('load-' . $plugin_page);
|
||||
|
Loading…
Reference in New Issue
Block a user