diff --git a/.gitignore b/.gitignore index 454a19e..60868f2 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,5 @@ img/.DS_Store *.sublime-workspace .vscode/launch.json .vscode/settings.json +.idea/shelf +.idea/sonarlint diff --git a/README.txt b/README.txt index 67ee153..2eb0d7e 100644 --- a/README.txt +++ b/README.txt @@ -3,7 +3,7 @@ Contributors: sailthru-wp Tags: personalization, email, Requires at least: 5.5 Tested up to: 5.7 -Stable tag: 4.0.3 +Stable tag: 4.1.0 Provides an integration with Sailthru @@ -28,4 +28,4 @@ https://getstarted.sailthru.com/integrations/wordpress/wordpress-plugin/ = v4.0.0 = This version supports Wordpress version 5.5 and isn't backwards compatible with older Wordpress versions. -Only upgrade if using Wordpress version 5.5 or greater. \ No newline at end of file +Only upgrade if using Wordpress version 5.5 or greater. diff --git a/changelog.md b/changelog.md index 714eb56..9fe93de 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,9 @@ # Changelog +## v4.1.0 (2021-03-23) +Fixed JQUery queries without scope hidding non-Sailthru elements +Added delete from Sailthru when item is sent to trash in Wordpress + ## v4.0.3 (2021-01-20) Fixed bug where an unset Welcome Template breaks the signup widget diff --git a/classes/class-sailthru-content.php b/classes/class-sailthru-content.php index a4d59b5..7d395b6 100644 --- a/classes/class-sailthru-content.php +++ b/classes/class-sailthru-content.php @@ -4,12 +4,12 @@ class Sailthru_Content_Settings { public function __construct() { - // make sure the priority is above the default of 10, the meta boxes are saved first. + // make sure the priority is above the default of 10, the meta boxes are saved first. add_action( 'admin_menu', array( $this, 'add_admin_menu' ), 11 ); add_action( 'admin_init', array( $this, 'init_settings' ), 11 ); add_action( 'save_post', array( $this, 'sailthru_save_post' ), 11, 3 ); add_action( 'wp_head', array( $this, 'generate_meta_tags' ) ); - + add_action( 'wp_trash_post', array( $this, 'sailthru_delete_post'), 11, 2); } public function add_admin_menu() { @@ -51,7 +51,7 @@ public function init_settings() { // Only show these fields if the status has been enabled if ( isset ( $options['sailthru_content_api_status'] ) && 'true' === $options['sailthru_content_api_status'] ) { - + add_settings_field( 'sailthru_spider_status', __( 'Spider', 'text_domain' ), @@ -116,7 +116,7 @@ public function page_layout() { } // Admin Page Layout - echo '