403Webshell
Server IP : 104.21.14.103  /  Your IP : 52.15.52.31
Web Server : LiteSpeed
System : Linux business53.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64
User : giankuin ( 1871)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /proc/self/root/home/giankuin/thietke365.net/wp-content/plugins/mailpoet/lib/Referrals/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/self/root/home/giankuin/thietke365.net/wp-content/plugins/mailpoet/lib/Referrals/ReferralDetector.php
<?php // phpcs:ignore SlevomatCodingStandard.TypeHints.DeclareStrictTypes.DeclareStrictTypesMissing

namespace MailPoet\Referrals;

if (!defined('ABSPATH')) exit;


use MailPoet\Settings\SettingsController;
use MailPoet\WP\Functions as WPFunctions;

class ReferralDetector {
  const REFERRAL_CONSTANT_NAME = 'MAILPOET_REFERRAL_ID';
  const REFERRAL_SETTING_NAME = 'referral_id';

  /** @var WPFunctions */
  private $wp;

  /** @var SettingsController */
  private $settings;

  public function __construct(
    WPFunctions $wp,
    SettingsController $settings
  ) {
    $this->wp = $wp;
    $this->settings = $settings;
  }

  public function detect() {
    $referralId = $this->settings->get(self::REFERRAL_SETTING_NAME, null);
    if ($referralId) {
      return $referralId;
    }
    $referralId = $this->wp->getOption(self::REFERRAL_CONSTANT_NAME, null);
    if ($referralId === null && defined(self::REFERRAL_CONSTANT_NAME)) {
      $referralId = constant(self::REFERRAL_CONSTANT_NAME);
    }
    if ($referralId !== null) {
      $this->settings->set(self::REFERRAL_SETTING_NAME, $referralId);
    }
    return $referralId;
  }
}

Youez - 2016 - github.com/yon3zu
LinuXploit