Changeset 3362936 for wpvulnerability/trunk/wpvulnerability-run.php
- Timestamp:
- 09/17/2025 06:49:03 AM (6 months ago)
- File:
-
- 1 edited
-
wpvulnerability/trunk/wpvulnerability-run.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wpvulnerability/trunk/wpvulnerability-run.php
r3161036 r3362936 158 158 // Add wpvulnerability-config option if it does not exist. 159 159 if ( ! $config_key( 'wpvulnerability-config' ) ) { 160 $default_config = array( 161 'emails' => get_bloginfo( 'admin_email' ), 162 'period' => 'weekly', 163 ); 164 $add_option( 'wpvulnerability-config', $default_config ); 160 $default_config = array( 161 'emails' => get_bloginfo( 'admin_email' ), 162 'period' => 'weekly', 163 'day' => 'monday', 164 'hour' => 0, 165 'minute' => 0, 166 'cache' => 12, 167 'notify' => array( 168 'email' => 'y', 169 'slack' => 'n', 170 'teams' => 'n', 171 ), 172 'slack_webhook' => '', 173 'teams_webhook' => '', 174 ); 175 $add_option( 'wpvulnerability-config', $default_config ); 165 176 } 166 177 … … 235 246 'sqlite' => 0, 236 247 ); 237 $current_option = $config_key( 'wpvulnerability-analyze' ); 248 249 foreach ( array_keys( $default_analyze ) as $component ) { 250 $constant = 'WPVULNERABILITY_HIDE_' . strtoupper( $component ); 251 if ( defined( $constant ) && constant( $constant ) ) { 252 $default_analyze[ $component ] = 1; 253 } 254 } 255 $current_option = $config_key( 'wpvulnerability-analyze' ); 238 256 239 257 if ( false === $current_option ) { … … 484 502 485 503 if ( in_array( $type, $valid_types, true ) ) { 504 $constant = 'WPVULNERABILITY_HIDE_' . strtoupper( $type ); 505 if ( defined( $constant ) && constant( $constant ) ) { 506 return false; 507 } 508 486 509 return ! ( isset( $wpvulnerability_analyze[ $type ] ) && (int) $wpvulnerability_analyze[ $type ] ); 487 510 }
Note: See TracChangeset
for help on using the changeset viewer.