Completed
Push — feature/videopress-uploader ( 58b703...e9e1f9 )
by
unknown
104:20 queued 95:05
created

3rd-party/polldaddy.php (1 issue)

Severity

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
3
class Jetpack_Sync {
4
	static function sync_options() {
5
		_deprecated_function( __METHOD__, '4.1.0', 'jetpack_whitelist_options filter' );
6
		$options = func_get_args();
7
		// first argument is the file but we don't care about that any more.
8
		$file = array_shift( $options );
0 ignored issues
show
$file is not used, you could remove the assignment.

This check looks for variable assignements that are either overwritten by other assignments or where the variable is not used subsequently.

$myVar = 'Value';
$higher = false;

if (rand(1, 6) > 3) {
    $higher = true;
} else {
    $higher = false;
}

Both the $myVar assignment in line 1 and the $higher assignment in line 2 are dead. The first because $myVar is never used and the second because $higher is always overwritten for every possible time line.

Loading history...
9
		if ( is_array( $options ) ) {
10
			$client_sync = Jetpack_Sync_Client::getInstance();
11
			$client_sync->set_options_whitelist( array_merge( $options, $client_sync->get_options_whitelist() ) );
12
		}
13
	}
14
}
15