403Webshell
Server IP : 69.72.244.102  /  Your IP : 216.73.216.164
Web Server : LiteSpeed
System : Linux s3434.fra1.stableserver.net 4.18.0-513.24.1.lve.2.el8.x86_64 #1 SMP Fri May 24 12:42:50 UTC 2024 x86_64
User : konzalta ( 1271)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /proc/thread-self/cwd/wp-content/plugins/master-addons/inc/classes/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/thread-self/cwd/wp-content/plugins/master-addons/inc/classes/Upgrades.php
<?php

namespace MasterAddons\Inc\Classes;

class Upgrades
{

	/**
	 * Plugin version option key
	 *
	 * @var string $option_name
	 */
	protected $option_name = '_master_addons_version';

	/**
	 * Lists of upgrades
	 *
	 * @var string[] $upgrades
	 */
	protected $upgrades = [
		'2.0.8.9'   => 'Upgrades/upgrade-2.0.8.9.php',
	];

	/**
	 * Get plugin installed version
	 *
	 * @return string
	 */
	protected function get_installed_version()
	{
		return get_option($this->option_name, '1.0.0');
	}

	/**
	 * Check if plugin's update is available
	 *
	 * @return bool
	 */
	public function if_updates_available()
	{
		if (version_compare($this->get_installed_version(), JLTMA_VER, '<')) {
			return true;
		}

		return false;
	}

	/**
	 * Run plugin updates
	 *
	 * @return void
	 */
	public function run_updates()
	{
		$installed_version = $this->get_installed_version();
		$path              = trailingslashit(__DIR__);

		foreach ($this->upgrades as $version => $file) {
			if (version_compare($installed_version, $version, '<')) {
				include $path . $file;
			}
		}

		// update_option( $this->option_name, JLTMA_VER );
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit