From eb444db5b88ef343c72856fd3157a24cd25184fc Mon Sep 17 00:00:00 2001 From: savvasha Date: Sun, 7 May 2023 17:16:44 +0300 Subject: [PATCH] FIX: Use of undefined constant SP_PLUGIN_FILE FIX: Use of undefined constant SP_PLUGIN_FILE - assumed 'SP_PLUGIN_FILE' (this will throw an Error in a future version of PHP) --- includes/class-sp-install.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/includes/class-sp-install.php b/includes/class-sp-install.php index 42980bc1..65d8b6c6 100644 --- a/includes/class-sp-install.php +++ b/includes/class-sp-install.php @@ -23,6 +23,9 @@ if ( ! class_exists( 'SP_Install' ) ) : * Hook in tabs. */ public function __construct() { + if ( ! defined( 'SP_PLUGIN_FILE' ) ) { + define( 'SP_PLUGIN_FILE', __FILE__ ); + } register_activation_hook( SP_PLUGIN_FILE, array( $this, 'install' ) ); if ( defined( 'SP_PRO_PLUGIN_FILE' ) ) {