Skip to content

Commit ab0cbaa

Browse files
authored
In 1934 bulk tags fix (#100)
* [IN-1934] Fixed tags not propagating for bulk edit
1 parent 5b79e9d commit ab0cbaa

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

README.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Contributors: sailthru-wp
33
Tags: personalization, email,
44
Requires at least: 5.5
55
Tested up to: 5.7
6-
Stable tag: 4.1.0
6+
Stable tag: 4.1.1
77

88
Provides an integration with Sailthru
99

changelog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Changelog
22

3+
## v4.1.1 (2021-05-25)
4+
Fixed Bulk Edit not propagating category and Wordpress tags properly
5+
36
## v4.1.0 (2021-03-23)
47
Fixed JQUery queries without scope hidding non-Sailthru elements
58
Added delete from Sailthru when item is sent to trash in Wordpress

classes/class-sailthru-content.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -470,15 +470,15 @@ function generate_tags( $post_id ) {
470470
// Add WordPress tags if option set.
471471
if ( isset( $options['sailthru_interest_tag_options'] ) && in_array( 'wordpress_tags',$options['sailthru_interest_tag_options'] ) ) {
472472

473-
$wp_tags = get_the_tags();
473+
$wp_tags = get_the_tags( $post_id );
474474
if ( $wp_tags ) {
475475
$post_tags .= ',' .esc_attr( implode( ',', wp_list_pluck( $wp_tags, 'name' ) ) );
476476
}
477477
}
478478

479479
// Add WordPress categories if option set.
480480
if ( isset( $options['sailthru_interest_tag_options'] ) && in_array( 'wordpress_categories', $options['sailthru_interest_tag_options'] ) ) {
481-
$post_categories = get_the_category( $post->ID );
481+
$post_categories = get_the_category( $post_id );
482482
foreach ( $post_categories as $post_category ) {
483483
$post_tags .= ','. $post_category->name;
484484
}

plugin.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Plugin Name: Sailthru for WordPress
44
Plugin URI: http://sailthru.com/
55
Description: Add the power of Sailthru to your WordPress set up.
6-
Version: 4.1.0
6+
Version: 4.1.1
77
Requires at least: 5.5
88
Author: Sailthru
99
Author URI: http://sailthru.com
@@ -36,7 +36,7 @@
3636
* @var const $version The current version of the plugin.
3737
*/
3838
if ( ! defined( 'SAILTHRU_PLUGIN_VERSION' ) ) {
39-
define( 'SAILTHRU_PLUGIN_VERSION', '4.1.0' );
39+
define( 'SAILTHRU_PLUGIN_VERSION', '4.1.1' );
4040
}
4141

4242
if ( ! defined( 'SAILTHRU_PLUGIN_PATH' ) ) {

0 commit comments

Comments
 (0)