From 09e098d055d6eaa3121718ebe70a9242225e3ef8 Mon Sep 17 00:00:00 2001 From: Diego Orozco Date: Thu, 24 Oct 2024 08:59:24 -0700 Subject: [PATCH] fix deprecation warnings in PHP >= 8.2 --- devtools_wp/Dockerfile | 4 ++-- drip.php | 4 ++-- readme.txt | 6 +++++- src/class-drip-woocommerce-plugin-view.php | 4 ++-- src/snippet.js.php | 2 +- 5 files changed, 12 insertions(+), 8 deletions(-) diff --git a/devtools_wp/Dockerfile b/devtools_wp/Dockerfile index 17c9436..641ca7a 100644 --- a/devtools_wp/Dockerfile +++ b/devtools_wp/Dockerfile @@ -1,6 +1,6 @@ -FROM wordpress:6.6.2-php8.1-apache +FROM wordpress:6.6.2-php8.3-apache RUN curl https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar -o /usr/local/bin/wp && chmod +x /usr/local/bin/wp RUN apt-get update && apt-get install -y less unzip vim wget vim-tiny net-tools -RUN curl https://downloads.wordpress.org/plugin/woocommerce.9.3.1.zip -o /usr/src/woocommerce.zip && cd /usr/src/wordpress/wp-content/plugins && unzip /usr/src/woocommerce.zip +RUN curl https://downloads.wordpress.org/plugin/woocommerce.9.3.3.zip -o /usr/src/woocommerce.zip && cd /usr/src/wordpress/wp-content/plugins && unzip /usr/src/woocommerce.zip diff --git a/drip.php b/drip.php index fd27c58..accae7c 100644 --- a/drip.php +++ b/drip.php @@ -9,13 +9,13 @@ Plugin Name: Drip for WooCommerce Plugin URI: https://github.com/DripEmail/drip-woocommerce Description: A WordPress plugin to connect to Drip's WooCommerce integration -Version: 1.1.7 +Version: 1.1.8 Author: Drip Author URI: https://www.drip.com/ License: GPLv2 WC requires at least: 3.0 -WC tested up to: 9.3.1 +WC tested up to: 9.3.3 */ defined( 'ABSPATH' ) || die( 'Executing outside of the WordPress context.' ); diff --git a/readme.txt b/readme.txt index 06dd91f..eaa8af7 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: getdrip Tags: ecommerce, emailmarketing, marketingautomation, emailmarketingautomation, woocommerce, drip Requires at least: 4.6 Tested up to: 6.6.2 -Stable tag: 1.1.7 +Stable tag: 1.1.8 Requires PHP: 5.6 License: GPLv2 License URI: https://www.gnu.org/licenses/gpl-2.0.html @@ -74,6 +74,10 @@ The philosophy behind this plugin is to do as little as possible in it, and as m * Your change here! += 1.1.8 = + +* Fix deprecation warnings for PHP 8.2 + = 1.1.7 = * Implement `drip_set_snippet_script_type` and `drip_set_snippet_script_additional_attributes` filters to add custom attributes in Drip's JS Snippet diff --git a/src/class-drip-woocommerce-plugin-view.php b/src/class-drip-woocommerce-plugin-view.php index 302e5bd..c1523f7 100644 --- a/src/class-drip-woocommerce-plugin-view.php +++ b/src/class-drip-woocommerce-plugin-view.php @@ -49,8 +49,8 @@ private function integrations_url() { $account_id = WC_Admin_Settings::get_option( Drip_Woocommerce_Settings::ACCOUNT_ID_KEY ); $account_segment = ''; if ( ! empty( $account_id ) ) { - $account_segment = "${account_id}/"; + $account_segment = "{$account_id}/"; } - return "Integration Settings"; + return "Integration Settings"; } } diff --git a/src/snippet.js.php b/src/snippet.js.php index 93bc860..f26007b 100644 --- a/src/snippet.js.php +++ b/src/snippet.js.php @@ -21,7 +21,7 @@ var dc = document.createElement('script'); dc.type = ''; dc.async = true; - dc.src = '//tag.getdrip.com/.js'; + dc.src = 'https://tag.getdrip.com/.js'; $attval) {