PATH:
home
/
lab2454c
/
carbonbullion.com
/
wp-content
/
plugins
/
mailpoet
/
lib
/
Config
<?php // phpcs:ignore SlevomatCodingStandard.TypeHints.DeclareStrictTypes.DeclareStrictTypesMissing namespace MailPoet\Config; if (!defined('ABSPATH')) exit; use MailPoet\WP\Functions as WPFunctions; class Router { /** @var WPFunctions */ private $wp; public function __construct( WPFunctions $wp ) { $this->wp = $wp; } public function checkRedirects(): void { $url = null; if (isset($_GET['page']) && sanitize_text_field(wp_unslash($_GET['page'])) === 'mailpoet-newsletters') { $url = $this->checkNewslettersRedirect(); } if (!$url) return; $this->redirect($url); } private function checkNewslettersRedirect(): ?string { if (isset($_GET['stats'])) { return '/wp-admin/admin.php?page=mailpoet-newsletters#/stats/' . sanitize_text_field(wp_unslash($_GET['stats'])); } return null; } private function redirect(string $url): void { $this->wp->wpSafeRedirect( $this->wp->getSiteUrl(null, $url) ); exit; } }
[-] Localizer.php
[edit]
[-] TwigFileSystemCache.php
[edit]
[-] SubscriberChangesNotifier.php
[edit]
[-] Activator.php
[edit]
[-] DatabaseInitializer.php
[edit]
[-] index.php
[edit]
[+]
..
[+]
PopulatorData
[-] SilentUpgraderSkin.php
[edit]
[-] AssetsLoader.php
[edit]
[-] Shortcodes.php
[edit]
[-] ServicesChecker.php
[edit]
[-] Changelog.php
[edit]
[-] Hooks.php
[edit]
[-] TwigEnvironment.php
[edit]
[-] PrivacyPolicy.php
[edit]
[-] Updater.php
[edit]
[-] Capabilities.php
[edit]
[-] AccessControl.php
[edit]
[-] Populator.php
[edit]
[-] DeactivationPoll.php
[edit]
[-] Renderer.php
[edit]
[-] PluginActivatedHook.php
[edit]
[-] TranslationUpdater.php
[edit]
[-] PersonalDataErasers.php
[edit]
[-] Installer.php
[edit]
[-] DeferredAdminNotices.php
[edit]
[-] HooksWooCommerce.php
[edit]
[-] Database.php
[edit]
[-] Menu.php
[edit]
[-] Env.php
[edit]
[-] Initializer.php
[edit]
[-] RequirementsChecker.php
[edit]
[-] RendererFactory.php
[edit]
[-] Router.php
[edit]
[-] PersonalDataExporters.php
[edit]