[CodeFactor] Apply fixes to commit 7e3b1f2

[ci skip] [skip ci]
This commit is contained in:
codefactor-io 2020-03-26 14:11:33 +00:00
parent 7e3b1f2601
commit bd796ad047
31 changed files with 960 additions and 793 deletions

View file

@ -129,8 +129,8 @@ class MainWP_Child_Vulnerability_Checker {
function check_themes( $force = false) {
require_once( ABSPATH . 'wp-admin/includes/misc.php' );
require_once( ABSPATH . 'wp-admin/includes/theme.php' );
require_once ABSPATH . 'wp-admin/includes/misc.php';
require_once ABSPATH . 'wp-admin/includes/theme.php';
if ( current_user_can( 'switch_themes' ) ) {
$themes = wp_prepare_themes_for_js();
@ -156,8 +156,9 @@ class MainWP_Child_Vulnerability_Checker {
$th_vulner_data = array();
foreach($th_data['vulnerabilities'] as $vuln_data) {
if (empty($vuln_data))
if (empty($vuln_data)) {
continue;
}
if ( isset($vuln_data['fixed_in']) && version_compare( $th['version'], $vuln_data['fixed_in'] ) >= 0 ) {
continue;