WordPress Social Sharing Plugin – Sassy Social Share - Version 3.3.42

Version Description

[23 May 2022] = * [Improvement] Code quality improvement

Download this release

Release Info

Developer Heateor
Plugin Icon 128x128 WordPress Social Sharing Plugin – Sassy Social Share
Version 3.3.42
Comparing to
See all releases

Code changes from version 3.3.41 to 3.3.42

admin/class-sassy-social-share-admin.php CHANGED
@@ -281,14 +281,7 @@ class Sassy_Social_Share_Admin {
281
  return $post_id;
282
  }
283
  }
284
- if ( isset( $_POST['_heateor_sss_meta'] ) && is_array( $_POST['_heateor_sss_meta'] ) ) {
285
- $newData = $_POST['_heateor_sss_meta'];
286
- foreach ( $_POST['_heateor_sss_meta'] as $key => $value ) {
287
- $newData[$key] = sanitize_text_field ( $value );
288
- }
289
- } else {
290
- $newData = array( 'sharing' => 0, 'vertical_sharing' => 0 );
291
- }
292
  update_post_meta( $post_id, '_heateor_sss_meta', $newData );
293
  return $post_id;
294
 
@@ -433,10 +426,11 @@ class Sassy_Social_Share_Admin {
433
  */
434
  private function sanitize_configuration_array( $config_value ) {
435
 
436
- if ( is_string( $config_value ) ) {
 
 
437
  return sanitize_text_field( $config_value );
438
  }
439
- return $config_value;
440
 
441
  }
442
 
@@ -672,7 +666,7 @@ class Sassy_Social_Share_Admin {
672
  }
673
 
674
  if ( version_compare( '3.2.5', $this->version ) <= 0 ) {
675
- if ( (isset( $this->options['hor_enable'] ) && isset( $this->options['horizontal_re_providers'] ) && in_array( 'twitter', $this->options['horizontal_re_providers'] ) && ( isset( $this->options['horizontal_counts'] ) || isset( $this->options['horizontal_total_shares'] ) ) ) || ( isset( $this->options['vertical_enable'] ) && isset( $this->options['vertical_re_providers'] ) && in_array( 'twitter', $this->options['vertical_re_providers'] ) && ( isset($this->options['vertical_counts'] ) || isset( $this->options['vertical_total_shares'] ) ) ) ) {
676
  if ( ! get_option( 'heateor_sss_twitter_share_notification_read' ) ) {
677
  ?>
678
  <script type="text/javascript">
281
  return $post_id;
282
  }
283
  }
284
+ $newData = isset( $_POST['_heateor_sss_meta'] ) && is_array( $_POST['_heateor_sss_meta'] ) ? array_map('sanitize_text_field', $_POST['_heateor_sss_meta'] ) : array( 'sharing' => 0, 'vertical_sharing' => 0 );
 
 
 
 
 
 
 
285
  update_post_meta( $post_id, '_heateor_sss_meta', $newData );
286
  return $post_id;
287
 
426
  */
427
  private function sanitize_configuration_array( $config_value ) {
428
 
429
+ if ( is_array( $config_value ) ) {
430
+ return array_map( array( $this, 'sanitize_configuration_array' ), $config_value );
431
+ } else {
432
  return sanitize_text_field( $config_value );
433
  }
 
434
 
435
  }
436
 
666
  }
667
 
668
  if ( version_compare( '3.2.5', $this->version ) <= 0 ) {
669
+ if ( ( isset( $this->options['hor_enable'] ) && isset( $this->options['horizontal_re_providers'] ) && in_array( 'twitter', $this->options['horizontal_re_providers'] ) && ( isset( $this->options['horizontal_counts'] ) || isset( $this->options['horizontal_total_shares'] ) ) ) || ( isset( $this->options['vertical_enable'] ) && isset( $this->options['vertical_re_providers'] ) && in_array( 'twitter', $this->options['vertical_re_providers'] ) && ( isset($this->options['vertical_counts'] ) || isset( $this->options['vertical_total_shares'] ) ) ) ) {
670
  if ( ! get_option( 'heateor_sss_twitter_share_notification_read' ) ) {
671
  ?>
672
  <script type="text/javascript">
admin/partials/sassy-social-share-options-page.php CHANGED
@@ -2037,7 +2037,7 @@ defined( 'ABSPATH' ) or die( "Cheating........Uh!!" );
2037
  <td colspan="2">
2038
  <textarea id="heateor_sss_import_config_txt" rows="5" cols="50"></textarea>
2039
  <br/>
2040
- <input type="button" class="button-primary" value="<?php _e( "Import Configuration", 'sassy-social-share' ); ?>" onclick="heateorSssImportConfig()" />
2041
  <div class="heateor_sss_clear"></div>
2042
  <img src="<?php echo plugins_url( '../../images/ajax_loader.gif', __FILE__ ) ?>" id="import_config_loading" style="display:none;margin-top:5px" />
2043
  </td>
2037
  <td colspan="2">
2038
  <textarea id="heateor_sss_import_config_txt" rows="5" cols="50"></textarea>
2039
  <br/>
2040
+ <input type="button" class="button-primary" value="<?php _e( "Import Configuration", 'sassy-social-share' ); ?>" onclick="heateorSssImportConfig()" style="margin-top:10px" />
2041
  <div class="heateor_sss_clear"></div>
2042
  <img src="<?php echo plugins_url( '../../images/ajax_loader.gif', __FILE__ ) ?>" id="import_config_loading" style="display:none;margin-top:5px" />
2043
  </td>
public/class-sassy-social-share-public.php CHANGED
@@ -1149,17 +1149,6 @@ class Sassy_Social_Share_Public {
1149
 
1150
  }
1151
 
1152
- /**
1153
- * Sanitize the share counts of the passed array
1154
- *
1155
- * @since 3.3.41
1156
- */
1157
- private function sanitize_share_count_array( $share_count ) {
1158
-
1159
- return sanitize_text_field( $share_count );
1160
-
1161
- }
1162
-
1163
  /**
1164
  * Save Facebook share counts in transient
1165
  *
@@ -1168,7 +1157,7 @@ class Sassy_Social_Share_Public {
1168
  public function save_facebook_shares() {
1169
 
1170
  if ( isset( $_GET['share_counts'] ) && is_array( $_GET['share_counts'] ) && count( $_GET['share_counts'] ) > 0 ) {
1171
- $target_urls = array_map( array( $this, 'sanitize_share_count_array' ), $_GET['share_counts'] );
1172
  } else {
1173
  $this->ajax_response( array( 'status' => 0, 'message' => __( 'Invalid request' ) ) );
1174
  }
1149
 
1150
  }
1151
 
 
 
 
 
 
 
 
 
 
 
 
1152
  /**
1153
  * Save Facebook share counts in transient
1154
  *
1157
  public function save_facebook_shares() {
1158
 
1159
  if ( isset( $_GET['share_counts'] ) && is_array( $_GET['share_counts'] ) && count( $_GET['share_counts'] ) > 0 ) {
1160
+ $target_urls = array_map( 'intval', $_GET['share_counts'] );
1161
  } else {
1162
  $this->ajax_response( array( 'status' => 0, 'message' => __( 'Invalid request' ) ) );
1163
  }
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: Heateor, jatin8heateor, farhan8heateor
3
  Donate link: https://www.heateor.com/donate/?action=Sassy+Social+Share
4
  Tags: social share, social sharing, social media share, share facebook, facebook social share, wordpress social share, share buttons, social share buttons, facebook like, twitter tweet, whatsapp share, line share, gab share, gab, parler share, gettr, gettr share, mewe share, mewe
5
  Requires at least: 2.5.0
6
- Tested up to: 5.9.3
7
- Stable tag: 3.3.41
8
  License: GPLv2 or later
9
 
10
  Slickest, Simplest and Optimized Share buttons. Facebook, Twitter, Reddit, Pinterest, Whatsapp, Parler, Gab, Gettr and over 100 more.
@@ -125,6 +125,9 @@ Yes, we can help you with it. Just drop an email at support[at]heateor[dot]com
125
  4. **Universal Sharing Popup**: Universal Sharing popup having all the supported sharing and bookmarking services
126
 
127
  == Changelog ==
 
 
 
128
  = 3.3.41 [11 May 2022] =
129
  * [Improvement] Code quality improvement
130
 
@@ -1189,4 +1192,7 @@ Yes, we can help you with it. Just drop an email at support[at]heateor[dot]com
1189
  * [Improvement] Performmance improvement
1190
 
1191
  = 3.3.41 [11 May 2022] =
 
 
 
1192
  * [Improvement] Code quality improvement
3
  Donate link: https://www.heateor.com/donate/?action=Sassy+Social+Share
4
  Tags: social share, social sharing, social media share, share facebook, facebook social share, wordpress social share, share buttons, social share buttons, facebook like, twitter tweet, whatsapp share, line share, gab share, gab, parler share, gettr, gettr share, mewe share, mewe
5
  Requires at least: 2.5.0
6
+ Tested up to: 6.0
7
+ Stable tag: 3.3.42
8
  License: GPLv2 or later
9
 
10
  Slickest, Simplest and Optimized Share buttons. Facebook, Twitter, Reddit, Pinterest, Whatsapp, Parler, Gab, Gettr and over 100 more.
125
  4. **Universal Sharing Popup**: Universal Sharing popup having all the supported sharing and bookmarking services
126
 
127
  == Changelog ==
128
+ = 3.3.42 [23 May 2022] =
129
+ * [Improvement] Code quality improvement
130
+
131
  = 3.3.41 [11 May 2022] =
132
  * [Improvement] Code quality improvement
133
 
1192
  * [Improvement] Performmance improvement
1193
 
1194
  = 3.3.41 [11 May 2022] =
1195
+ * [Improvement] Code quality improvement
1196
+
1197
+ = 3.3.42 [23 May 2022] =
1198
  * [Improvement] Code quality improvement
sassy-social-share.php CHANGED
@@ -6,7 +6,7 @@
6
  * Plugin Name: Sassy Social Share
7
  * Plugin URI: https://www.heateor.com
8
  * Description: Slickest, Simplest and Optimized Share buttons. Facebook, Twitter, Reddit, Pinterest, WhatsApp and over 100 more
9
- * Version: 3.3.41
10
  * Author: Team Heateor
11
  * Author URI: https://www.heateor.com
12
  * Text Domain: sassy-social-share
@@ -20,7 +20,7 @@ if ( ! defined( 'WPINC' ) ) {
20
  die;
21
  }
22
 
23
- define( 'HEATEOR_SSS_VERSION', '3.3.41' );
24
  define( 'HEATEOR_SSS_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
25
 
26
  // core plugin class object
6
  * Plugin Name: Sassy Social Share
7
  * Plugin URI: https://www.heateor.com
8
  * Description: Slickest, Simplest and Optimized Share buttons. Facebook, Twitter, Reddit, Pinterest, WhatsApp and over 100 more
9
+ * Version: 3.3.42
10
  * Author: Team Heateor
11
  * Author URI: https://www.heateor.com
12
  * Text Domain: sassy-social-share
20
  die;
21
  }
22
 
23
+ define( 'HEATEOR_SSS_VERSION', '3.3.42' );
24
  define( 'HEATEOR_SSS_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
25
 
26
  // core plugin class object