From 1ac96224565b6b7ddde5137c688e284611cbf5c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Garc=C3=ADa?= <lucas@codeccoop.org> Date: Sat, 4 May 2024 04:42:51 +0200 Subject: [PATCH] feat: remove enqueue scripts --- wpct-erp-forms.php | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/wpct-erp-forms.php b/wpct-erp-forms.php index a66f01a..dc20946 100755 --- a/wpct-erp-forms.php +++ b/wpct-erp-forms.php @@ -60,7 +60,6 @@ class Wpct_Erp_Forms extends Abstract\Plugin public function init() { - add_action('wp_enqueue_scripts', [$this, 'enqueue_scripts']); } public static function activate() @@ -70,33 +69,6 @@ class Wpct_Erp_Forms extends Abstract\Plugin public static function deactivate() { } - - public function enqueue_scripts() - { - if (isset($this->_integrations['wpcf7'])) { - wp_enqueue_style( - 'wpct-wpcf7-theme', - plugin_dir_url(__FILE__) . 'assets/css/wpct7-theme.css', - [], - WPCT_ERP_FORMS_VERSION, - ); - - wp_enqueue_script( - 'wpct-wpcf7-swv-validators', - plugin_dir_url(__FILE__) . 'assets/js/wpcf7-swv-validators.js', - [], - WPCT_ERP_FORMS_VERSION, - true, - ); - } elseif (isset($this->_integrations['gf'])) { - wp_register_script( - 'wpct-gf-app', - plugin_dir_url(__FILE__) . 'assets/js/gf.js', - [], - WPCT_ERP_FORMS_VERSION - ); - } - } } add_action('plugins_loaded', function () { -- GitLab