Edit File by line
/home/zeestwma/richards.../wp-conte.../plugins/hostinge.../includes
File: Hostinger.php
<?php
[0] Fix | Delete
[1] Fix | Delete
namespace Hostinger;
[2] Fix | Delete
[3] Fix | Delete
use Hostinger\Bootstrap;
[4] Fix | Delete
[5] Fix | Delete
defined( 'ABSPATH' ) || exit;
[6] Fix | Delete
[7] Fix | Delete
class Hostinger {
[8] Fix | Delete
protected string $plugin_name = 'Hostinger';
[9] Fix | Delete
protected string $version;
[10] Fix | Delete
[11] Fix | Delete
/**
[12] Fix | Delete
* @return void
[13] Fix | Delete
*/
[14] Fix | Delete
public function bootstrap(): void {
[15] Fix | Delete
$this->version = $this->get_plugin_version();
[16] Fix | Delete
$bootstrap = new Bootstrap();
[17] Fix | Delete
$bootstrap->run();
[18] Fix | Delete
}
[19] Fix | Delete
[20] Fix | Delete
/**
[21] Fix | Delete
* @return void
[22] Fix | Delete
*/
[23] Fix | Delete
public function run(): void {
[24] Fix | Delete
$this->bootstrap();
[25] Fix | Delete
}
[26] Fix | Delete
/** PHPCS:disable WordPress.NamingConventions.PrefixAllGlobals.VariableConstantNameFound */
[27] Fix | Delete
/**
[28] Fix | Delete
* Define constant
[29] Fix | Delete
*
[30] Fix | Delete
* @param string $name Constant name.
[31] Fix | Delete
* @param string|bool $value Constant value.
[32] Fix | Delete
*/
[33] Fix | Delete
private function define( string $name, $value ): void {
[34] Fix | Delete
if ( ! defined( $name ) ) {
[35] Fix | Delete
define( $name, $value );
[36] Fix | Delete
}
[37] Fix | Delete
}
[38] Fix | Delete
/** PHPCS:enable */
[39] Fix | Delete
/**
[40] Fix | Delete
* @return string
[41] Fix | Delete
*/
[42] Fix | Delete
private function get_plugin_version(): string {
[43] Fix | Delete
if ( defined( 'HOSTINGER_VERSION' ) ) {
[44] Fix | Delete
return HOSTINGER_VERSION;
[45] Fix | Delete
}
[46] Fix | Delete
[47] Fix | Delete
return '1.0.0';
[48] Fix | Delete
}
[49] Fix | Delete
}
[50] Fix | Delete
[51] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function