Skip to content

Commit 7be55c4

Browse files
committed
Fixes clear results on cron loads
1 parent 9e68e90 commit 7be55c4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/wpephpcompat.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,6 @@ function __construct( $dir ) {
8787
*/
8888
public function start_test() {
8989

90-
delete_option( 'wpephpcompat.scan_results' );
91-
//delete_option( 'wpephpcompat.test_version' );
92-
9390
$this->debug_log( 'startScan: ' . isset( $_POST['startScan'] ) );
9491
// Try to lock.
9592
$lock_result = add_option( 'wpephpcompat.lock', time(), '', 'no' );
@@ -118,6 +115,9 @@ public function start_test() {
118115
$this->debug_log( 'scan status: ' . $scan_status );
119116
if ( ! $scan_status ) {
120117

118+
// Clear the previous results.
119+
delete_option( 'wpephpcompat.scan_results' );
120+
121121
update_option( 'wpephpcompat.status', '1', false );
122122
update_option( 'wpephpcompat.test_version', $this->test_version, false );
123123
update_option( 'wpephpcompat.only_active', $this->only_active, false );

0 commit comments

Comments
 (0)