refactor: run rector DEAD_CODE ruleset

This commit is contained in:
Ben Goldsworthy 2021-05-02 10:18:47 +01:00
parent 35745a7623
commit 4299a71df5
5 changed files with 5 additions and 25 deletions

View file

@ -25,16 +25,6 @@ use footnotes\includes as Includes;
*/
class WYSIWYG {
/**
* The ID of this plugin.
*
* @access private
* @var string $plugin_name The ID of this plugin.
*
* @since 2.8.0
*/
private $plugin_name;
/**
* Initialize the class and set its properties.
*
@ -42,10 +32,8 @@ class WYSIWYG {
*
* @since 2.8.0
*/
public function __construct( $plugin_name ) {
$this->plugin_name = $plugin_name;
public function __construct()
{
}
/**

View file

@ -47,7 +47,7 @@ abstract class Engine {
*
* @since 1.5.0
*/
protected $a_str_sub_page_hook = null;
protected $a_str_sub_page_hook;
/**
* Stores all Sections for the child sub-page.
@ -286,7 +286,6 @@ abstract class Engine {
echo '<h2 class="nav-tab-wrapper">';
// Iterate through all register sections.
foreach ( $this->a_arr_sections as $l_str_id => $l_arr_description ) {
$l_str_tab_active = ( $l_str_id === $l_arr_active_section['id'] ) ? ' nav-tab-active' : '';
echo sprintf(
'<a class="nav-tab%s" href="?page=%s&t=%s">%s</a>',
( $l_str_id === $l_arr_active_section['id'] ) ? ' nav-tab-active' : '',

View file

@ -52,7 +52,6 @@ class Convert {
*
* @param int $p_int_value Value to be converted.
* @param bool $p_bool_upper_case Whether to convert the value to upper-case.
* @return string
*
* @since 1.0-gamma
* @todo Replace with built-in char casting.
@ -102,7 +101,6 @@ class Convert {
*
* @param int $p_int_value Value to be converted.
* @param bool $p_bool_upper_case Whether to convert the value to upper-case.
* @return string
*
* @since 1.0-gamma
*/

View file

@ -1112,7 +1112,7 @@ class Settings {
*
* @since 1.5.0
*/
private static $a_obj_instance = null;
private static $a_obj_instance;
/**
* Contains all Settings Container names.

View file

@ -797,9 +797,7 @@ class Parser {
foreach ( $l_arr_sections_raw as $l_str_section ) {
$l_arr_sections_processed[] = self::exec( $l_str_section, true );
}
$p_str_content = implode( $l_arr_sections_processed );
return $p_str_content;
return implode( $l_arr_sections_processed );
}
}
@ -1908,9 +1906,6 @@ class Parser {
$l_str_hard_link_address .= self::$a_str_post_container_id_compound;
$l_str_hard_link_address .= $l_str_footnote_id . '"';
$l_str_hard_link_address .= $l_str_use_backbutton_hint;
// Compose optional opening link tag with optional hard link, mandatory for instance.
self::$a_str_link_open_tag = '<a' . $l_str_hard_link_address;
self::$a_str_link_open_tag = ' class="footnote_hard_back_link">';
} else {