From 534d96f7129803b15fc04ae1c965b14d6ef1a8a1 Mon Sep 17 00:00:00 2001 From: Rami Yushuvaev Date: Wed, 6 May 2026 09:10:12 +0300 Subject: [PATCH] Fix: improve performance by loading Promotion only on WordPress admin --- src/php/Plugin.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/php/Plugin.php b/src/php/Plugin.php index d25a399c..b4ed4555 100644 --- a/src/php/Plugin.php +++ b/src/php/Plugin.php @@ -137,7 +137,10 @@ public function load_plugin() { new MCE_Plugin(); new Upgrader( PLUGIN_VERSION, $this->db ); new Admin_Bar(); - new Promotion_Manager(); + + if ( is_admin() ) { + new Promotion_Manager(); + } $this->init_snippet_files(); }