Facebook for WooCommerce - Version 2.1.1

Version Description

Download this release

Release Info

Developer SkyVerge
Plugin Icon Facebook for WooCommerce
Version 2.1.1
Comparing to
See all releases

Code changes from version 2.1.0 to 2.1.1

changelog.txt CHANGED
@@ -1,5 +1,8 @@
1
  *** Facebook for WooCommerce Changelog ***
2
 
 
 
 
3
  2020.10.26 - version 2.1.0
4
  * Feature - Set Google category at the shop level for the Facebook catalog sync (on the product sync tab).
5
  * Feature - Set Google category for the Facebook catalog sync at the WooCommerce category level.
1
  *** Facebook for WooCommerce Changelog ***
2
 
3
+ 2020.10.27 - version 2.1.1
4
+ * Fix - Adjust code syntax that may have issued errors in installations running PHP lower than 7.3
5
+
6
  2020.10.26 - version 2.1.0
7
  * Feature - Set Google category at the shop level for the Facebook catalog sync (on the product sync tab).
8
  * Feature - Set Google category for the Facebook catalog sync at the WooCommerce category level.
class-wc-facebookcommerce.php CHANGED
@@ -22,7 +22,7 @@ if ( ! class_exists( 'WC_Facebookcommerce' ) ) :
22
 
23
 
24
  /** @var string the plugin version */
25
- const VERSION = '2.1.0';
26
 
27
  /** @var string for backwards compatibility TODO: remove this in v2.0.0 {CW 2020-02-06} */
28
  const PLUGIN_VERSION = self::VERSION;
22
 
23
 
24
  /** @var string the plugin version */
25
+ const VERSION = '2.1.1';
26
 
27
  /** @var string for backwards compatibility TODO: remove this in v2.0.0 {CW 2020-02-06} */
28
  const PLUGIN_VERSION = self::VERSION;
facebook-for-woocommerce.php CHANGED
@@ -10,7 +10,7 @@
10
  * Description: Grow your business on Facebook! Use this official plugin to help sell more of your products using Facebook. After completing the setup, you'll be ready to create ads that promote your products and you can also create a shop section on your Page where customers can browse your products on Facebook.
11
  * Author: Facebook
12
  * Author URI: https://www.facebook.com/
13
- * Version: 2.1.0
14
  * Text Domain: facebook-for-woocommerce
15
  * WC requires at least: 3.5.0
16
  * WC tested up to: 4.6.1
10
  * Description: Grow your business on Facebook! Use this official plugin to help sell more of your products using Facebook. After completing the setup, you'll be ready to create ads that promote your products and you can also create a shop section on your Page where customers can browse your products on Facebook.
11
  * Author: Facebook
12
  * Author URI: https://www.facebook.com/
13
+ * Version: 2.1.1
14
  * Text Domain: facebook-for-woocommerce
15
  * WC requires at least: 3.5.0
16
  * WC tested up to: 4.6.1
i18n/languages/facebook-for-woocommerce.pot CHANGED
@@ -2,10 +2,10 @@
2
  # This file is distributed under the same license as the Facebook for WooCommerce package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Facebook for WooCommerce 2.1.0\n"
6
  "Report-Msgid-Bugs-To: "
7
  "https://woocommerce.com/my-account/marketplace-ticket-form/\n"
8
- "POT-Creation-Date: 2020-10-27 01:41:17+00:00\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=utf-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
@@ -240,7 +240,7 @@ msgstr ""
240
  msgid "Save changes"
241
  msgstr ""
242
 
243
- #: includes/Admin/Enhanced_Catalog_Attribute_Fields.php:103
244
  msgid "Show advanced options"
245
  msgstr ""
246
 
2
  # This file is distributed under the same license as the Facebook for WooCommerce package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Facebook for WooCommerce 2.1.1\n"
6
  "Report-Msgid-Bugs-To: "
7
  "https://woocommerce.com/my-account/marketplace-ticket-form/\n"
8
+ "POT-Creation-Date: 2020-10-27 11:58:58+00:00\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=utf-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
240
  msgid "Save changes"
241
  msgstr ""
242
 
243
+ #: includes/Admin/Enhanced_Catalog_Attribute_Fields.php:104
244
  msgid "Show advanced options"
245
  msgstr ""
246
 
includes/Admin/Enhanced_Catalog_Attribute_Fields.php CHANGED
@@ -81,7 +81,8 @@ class Enhanced_Catalog_Attribute_Fields {
81
  $this->extract_attribute( $optional_attributes, 'gender' ),
82
  ),
83
  function( $attr ) {
84
- return ! is_null( $attr ); },
 
85
  );
86
  }
87
 
81
  $this->extract_attribute( $optional_attributes, 'gender' ),
82
  ),
83
  function( $attr ) {
84
+ return ! is_null( $attr );
85
+ }
86
  );
87
  }
88
 
includes/Products.php CHANGED
@@ -1152,12 +1152,13 @@ class Products {
1152
 
1153
 
1154
  /**
1155
- * Helper function that gets and cleans the submitted values for enhanced
1156
- * catalog attributes from the request. Is used by both product categories
1157
- * and product pages.
1158
- * Returns an array that maps key to value.
1159
  *
1160
- * @return array
 
 
 
 
1161
  */
1162
  public static function get_enhanced_catalog_attributes_from_request() {
1163
  $prefix = Admin\Enhanced_Catalog_Attribute_Fields::FIELD_ENHANCED_CATALOG_ATTRIBUTE_PREFIX;
@@ -1174,13 +1175,12 @@ class Products {
1174
  function( $attrs, $attr_key ) use ( $prefix ) {
1175
  return array_merge(
1176
  $attrs,
1177
- array(
1178
- str_replace( $prefix, '', $attr_key ) =>
1179
- wc_clean( Framework\SV_WC_Helper::get_posted_value( $attr_key ) ),
1180
- ),
1181
  );
1182
  },
1183
- array(),
1184
  );
1185
  }
1186
 
1152
 
1153
 
1154
  /**
1155
+ * Gets and cleans the submitted values for enhanced catalog attributes from the request.
 
 
 
1156
  *
1157
+ * Helper function used by both product categories and product pages.
1158
+ *
1159
+ * @since 2.1.0
1160
+ *
1161
+ * @return array associative array
1162
  */
1163
  public static function get_enhanced_catalog_attributes_from_request() {
1164
  $prefix = Admin\Enhanced_Catalog_Attribute_Fields::FIELD_ENHANCED_CATALOG_ATTRIBUTE_PREFIX;
1175
  function( $attrs, $attr_key ) use ( $prefix ) {
1176
  return array_merge(
1177
  $attrs,
1178
+ [
1179
+ str_replace( $prefix, '', $attr_key ) => wc_clean( Framework\SV_WC_Helper::get_posted_value( $attr_key ) ),
1180
+ ]
 
1181
  );
1182
  },
1183
+ []
1184
  );
1185
  }
1186
 
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: facebook, automattic, woothemes
3
  Tags: facebook, shop, catalog, advertise, pixel, product
4
  Requires at least: 4.4
5
  Tested up to: 5.5.1
6
- Stable tag: 2.1.0
7
  Requires PHP: 5.6 or greater
8
  MySQL: 5.6 or greater
9
  License: GPLv2 or later
@@ -39,6 +39,9 @@ When opening a bug on GitHub, please give us as many details as possible.
39
 
40
  == Changelog ==
41
 
 
 
 
42
  = 2020.10.26 - version 2.1.0 =
43
  * Feature - Set Google category at the shop level for the Facebook catalog sync (on the product sync tab).
44
  * Feature - Set Google category for the Facebook catalog sync at the WooCommerce category level.
3
  Tags: facebook, shop, catalog, advertise, pixel, product
4
  Requires at least: 4.4
5
  Tested up to: 5.5.1
6
+ Stable tag: 2.1.1
7
  Requires PHP: 5.6 or greater
8
  MySQL: 5.6 or greater
9
  License: GPLv2 or later
39
 
40
  == Changelog ==
41
 
42
+ = 2020.10.27 - version 2.1.1 =
43
+ * Fix - Adjust code syntax that may have issued errors in installations running PHP lower than 7.3
44
+
45
  = 2020.10.26 - version 2.1.0 =
46
  * Feature - Set Google category at the shop level for the Facebook catalog sync (on the product sync tab).
47
  * Feature - Set Google category for the Facebook catalog sync at the WooCommerce category level.