Give – Donation Plugin and Fundraising Platform - Version 2.19.1

Version Description

Download this release

Release Info

Developer jason_the_adams
Plugin Icon 128x128 Give – Donation Plugin and Fundraising Platform
Version 2.19.1
Comparing to
See all releases

Code changes from version 1.9.0 to 2.19.1

give.php CHANGED
@@ -5,7 +5,7 @@
5
  * Description: The most robust, flexible, and intuitive way to accept donations on WordPress.
6
  * Author: GiveWP
7
  * Author URI: https://givewp.com/
8
- * Version: 2.19.0
9
  * Requires at least: 4.9
10
  * Requires PHP: 5.6
11
  * Text Domain: give
@@ -289,7 +289,7 @@ final class Give
289
  {
290
  // Plugin version.
291
  if ( ! defined('GIVE_VERSION')) {
292
- define('GIVE_VERSION', '2.19.0');
293
  }
294
 
295
  // Plugin Root File.
5
  * Description: The most robust, flexible, and intuitive way to accept donations on WordPress.
6
  * Author: GiveWP
7
  * Author URI: https://givewp.com/
8
+ * Version: 2.19.1
9
  * Requires at least: 4.9
10
  * Requires PHP: 5.6
11
  * Text Domain: give
289
  {
290
  // Plugin version.
291
  if ( ! defined('GIVE_VERSION')) {
292
+ define('GIVE_VERSION', '2.19.1');
293
  }
294
 
295
  // Plugin Root File.
includes/class-give-scripts.php CHANGED
@@ -586,7 +586,7 @@ class Give_Scripts {
586
  /**
587
  * Gutenberg admin scripts.
588
  *
589
- * @unreleased Remove undefined gutenberg.css
590
  */
591
  public function gutenberg_admin_scripts() {
592
 
586
  /**
587
  * Gutenberg admin scripts.
588
  *
589
+ * @since 2.19.0 Remove undefined gutenberg.css
590
  */
591
  public function gutenberg_admin_scripts() {
592
 
languages/give.pot CHANGED
@@ -2,14 +2,14 @@
2
  # This file is distributed under the same license as the Give - Donation Plugin plugin.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Give - Donation Plugin 2.19.0\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/givewp\n"
7
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
8
  "Language-Team: LANGUAGE <LL@li.org>\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
- "POT-Creation-Date: 2022-02-25T01:27:11+00:00\n"
13
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
14
  "X-Generator: WP-CLI 2.5.0\n"
15
  "X-Domain: give\n"
2
  # This file is distributed under the same license as the Give - Donation Plugin plugin.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Give - Donation Plugin 2.19.1\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/givewp\n"
7
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
8
  "Language-Team: LANGUAGE <LL@li.org>\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
+ "POT-Creation-Date: 2022-02-25T19:21:35+00:00\n"
13
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
14
  "X-Generator: WP-CLI 2.5.0\n"
15
  "X-Domain: give\n"
output.log CHANGED
@@ -16,40 +16,42 @@ c88517be8365: Pulling fs layer
16
  181891da1ea0: Pulling fs layer
17
  2a0fa75da19b: Pulling fs layer
18
  07289ea6b918: Pulling fs layer
19
- 4612e05a72cf: Waiting
20
- f1478d838f46: Waiting
21
  c88517be8365: Waiting
22
  142abe9b67c6: Waiting
23
  181891da1ea0: Waiting
24
  2a0fa75da19b: Waiting
25
  07289ea6b918: Waiting
 
 
 
 
 
 
26
  801bfaa63ef2: Verifying Checksum
27
  801bfaa63ef2: Download complete
28
  801bfaa63ef2: Pull complete
 
 
29
  4612e05a72cf: Verifying Checksum
 
30
  f1478d838f46: Verifying Checksum
31
  f1478d838f46: Download complete
32
- c88517be8365: Verifying Checksum
33
- c88517be8365: Download complete
34
- 320f26ee9b1c: Verifying Checksum
35
- 320f26ee9b1c: Download complete
36
- 30e209609427: Verifying Checksum
37
  30e209609427: Pull complete
 
 
 
38
  2a0fa75da19b: Verifying Checksum
39
  2a0fa75da19b: Download complete
40
- 320f26ee9b1c: Pull complete
41
  4612e05a72cf: Pull complete
42
- f1478d838f46: Pull complete
43
- 181891da1ea0: Verifying Checksum
44
- 181891da1ea0: Download complete
45
- c88517be8365: Pull complete
46
  142abe9b67c6: Verifying Checksum
47
  142abe9b67c6: Download complete
 
 
 
 
48
  142abe9b67c6: Pull complete
49
  181891da1ea0: Pull complete
50
  2a0fa75da19b: Pull complete
51
- 07289ea6b918: Verifying Checksum
52
- 07289ea6b918: Download complete
53
  07289ea6b918: Pull complete
54
  Digest: sha256:605a2cdc1df6638d3c9d4dcebd3d88748097618c3e5816a8549465408ae666ab
55
  Status: Downloaded newer image for docker.pkg.github.com/impress-org/givewp/php-actions_composer_givewp:php-7.2-build2
16
  181891da1ea0: Pulling fs layer
17
  2a0fa75da19b: Pulling fs layer
18
  07289ea6b918: Pulling fs layer
 
 
19
  c88517be8365: Waiting
20
  142abe9b67c6: Waiting
21
  181891da1ea0: Waiting
22
  2a0fa75da19b: Waiting
23
  07289ea6b918: Waiting
24
+ 4612e05a72cf: Waiting
25
+ f1478d838f46: Waiting
26
+ 30e209609427: Verifying Checksum
27
+ 30e209609427: Download complete
28
+ 320f26ee9b1c: Verifying Checksum
29
+ 320f26ee9b1c: Download complete
30
  801bfaa63ef2: Verifying Checksum
31
  801bfaa63ef2: Download complete
32
  801bfaa63ef2: Pull complete
33
+ c88517be8365: Verifying Checksum
34
+ c88517be8365: Download complete
35
  4612e05a72cf: Verifying Checksum
36
+ 4612e05a72cf: Download complete
37
  f1478d838f46: Verifying Checksum
38
  f1478d838f46: Download complete
 
 
 
 
 
39
  30e209609427: Pull complete
40
+ 181891da1ea0: Verifying Checksum
41
+ 181891da1ea0: Download complete
42
+ 320f26ee9b1c: Pull complete
43
  2a0fa75da19b: Verifying Checksum
44
  2a0fa75da19b: Download complete
 
45
  4612e05a72cf: Pull complete
 
 
 
 
46
  142abe9b67c6: Verifying Checksum
47
  142abe9b67c6: Download complete
48
+ f1478d838f46: Pull complete
49
+ c88517be8365: Pull complete
50
+ 07289ea6b918: Verifying Checksum
51
+ 07289ea6b918: Download complete
52
  142abe9b67c6: Pull complete
53
  181891da1ea0: Pull complete
54
  2a0fa75da19b: Pull complete
 
 
55
  07289ea6b918: Pull complete
56
  Digest: sha256:605a2cdc1df6638d3c9d4dcebd3d88748097618c3e5816a8549465408ae666ab
57
  Status: Downloaded newer image for docker.pkg.github.com/impress-org/givewp/php-actions_composer_givewp:php-7.2-build2
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: donation, donate, recurring donations, fundraising, crowdfunding
5
  Requires at least: 4.9
6
  Tested up to: 5.9
7
  Requires PHP: 5.6
8
- Stable tag: 2.19.0
9
  License: GPLv3
10
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
11
 
@@ -251,6 +251,9 @@ The 2% fee on Stripe donations only applies to donations taken via our free Stri
251
  8. GiveWP has a dedicated support team to help answer any questions you may have and help you through stumbling blocks.
252
 
253
  == Changelog ==
 
 
 
254
  = 2.19.0: February 24th, 2022 =
255
  * New: New reactive form table interface. The new forms table responds to your clicks instantly.
256
  * New: Stripe statement descriptors can now be set on a per account basis.
5
  Requires at least: 4.9
6
  Tested up to: 5.9
7
  Requires PHP: 5.6
8
+ Stable tag: 2.19.1
9
  License: GPLv3
10
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
11
 
251
  8. GiveWP has a dedicated support team to help answer any questions you may have and help you through stumbling blocks.
252
 
253
  == Changelog ==
254
+ = 2.19.1: February 25th, 2022 =
255
+ * Fix: Added backwards compatibility for Stripe statement descriptors that do not yet meet the new requirements.
256
+
257
  = 2.19.0: February 24th, 2022 =
258
  * New: New reactive form table interface. The new forms table responds to your clicks instantly.
259
  * New: Stripe statement descriptors can now be set on a per account basis.
src/PaymentGateways/Gateways/Stripe/Migrations/AddStatementDescriptorToStripeAccounts.php CHANGED
@@ -2,6 +2,7 @@
2
 
3
  namespace Give\PaymentGateways\Gateways\Stripe\Migrations;
4
 
 
5
  use Give\Framework\Migrations\Contracts\Migration;
6
  use Give\PaymentGateways\Stripe\Repositories\Settings;
7
  use Give\PaymentGateways\Stripe\Traits\HasStripeStatementDescriptorText;
@@ -16,6 +17,8 @@ class AddStatementDescriptorToStripeAccounts extends Migration
16
  /**
17
  * @inerhitDoc
18
  * @since 2.19.0
 
 
19
  */
20
  public function run()
21
  {
@@ -26,10 +29,9 @@ class AddStatementDescriptorToStripeAccounts extends Migration
26
  $statementDescriptor = give_get_option('stripe_statement_descriptor', get_bloginfo('name'));
27
  foreach ($allStripeAccount as $index => $stripAccount) {
28
  if (!isset($stripAccount['statement_descriptor'])) {
29
- $statementDescriptor = trim($statementDescriptor);
30
- $this->validateStatementDescriptor($statementDescriptor);
31
-
32
- $allStripeAccount[$index]['statement_descriptor'] = $statementDescriptor;
33
  }
34
  }
35
 
2
 
3
  namespace Give\PaymentGateways\Gateways\Stripe\Migrations;
4
 
5
+ use Exception;
6
  use Give\Framework\Migrations\Contracts\Migration;
7
  use Give\PaymentGateways\Stripe\Repositories\Settings;
8
  use Give\PaymentGateways\Stripe\Traits\HasStripeStatementDescriptorText;
17
  /**
18
  * @inerhitDoc
19
  * @since 2.19.0
20
+ * @since 2.19.1 Use old stripe statement descriptor requirements to filter text.
21
+ * https://github.com/impress-org/givewp/pull/6269
22
  */
23
  public function run()
24
  {
29
  $statementDescriptor = give_get_option('stripe_statement_descriptor', get_bloginfo('name'));
30
  foreach ($allStripeAccount as $index => $stripAccount) {
31
  if (!isset($stripAccount['statement_descriptor'])) {
32
+ $allStripeAccount[$index]['statement_descriptor'] = $this->filterOldStatementDescriptor(
33
+ $statementDescriptor
34
+ );
 
35
  }
36
  }
37
 
src/PaymentGateways/Stripe/Models/AccountDetail.php CHANGED
@@ -2,6 +2,7 @@
2
 
3
  namespace Give\PaymentGateways\Stripe\Models;
4
 
 
5
  use Give\Helpers\ArrayDataSet;
6
  use Give\PaymentGateways\Exceptions\InvalidPropertyName;
7
  use Give\PaymentGateways\Stripe\Traits\HasStripeStatementDescriptorText;
@@ -143,6 +144,8 @@ class AccountDetail
143
  * @see: https://github.com/impress-org/givewp/issues/6021
144
  *
145
  * @since 2.19.0
 
 
146
  * @deprecated
147
  *
148
  * @param array $args
@@ -154,8 +157,7 @@ class AccountDetail
154
  $propertyName = 'statement_descriptor';
155
  if (!array_key_exists($propertyName, $args) || empty($args[$propertyName])) {
156
  $statementDescriptor = give_get_option('stripe_statement_descriptor', get_bloginfo('name'));
157
- $this->validateStatementDescriptor($statementDescriptor);
158
- $args[$propertyName] = $statementDescriptor;
159
  }
160
 
161
  return $args;
2
 
3
  namespace Give\PaymentGateways\Stripe\Models;
4
 
5
+ use Exception;
6
  use Give\Helpers\ArrayDataSet;
7
  use Give\PaymentGateways\Exceptions\InvalidPropertyName;
8
  use Give\PaymentGateways\Stripe\Traits\HasStripeStatementDescriptorText;
144
  * @see: https://github.com/impress-org/givewp/issues/6021
145
  *
146
  * @since 2.19.0
147
+ * @since 2.19.1 Use old stripe statement descriptor requirements to filter text.
148
+ * https://github.com/impress-org/givewp/pull/6269
149
  * @deprecated
150
  *
151
  * @param array $args
157
  $propertyName = 'statement_descriptor';
158
  if (!array_key_exists($propertyName, $args) || empty($args[$propertyName])) {
159
  $statementDescriptor = give_get_option('stripe_statement_descriptor', get_bloginfo('name'));
160
+ $args[$propertyName] = $this->filterOldStatementDescriptor($statementDescriptor);
 
161
  }
162
 
163
  return $args;
src/PaymentGateways/Stripe/Traits/HasStripeStatementDescriptorText.php CHANGED
@@ -44,4 +44,24 @@ trait HasStripeStatementDescriptorText
44
  );
45
  }
46
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
47
  }
44
  );
45
  }
46
  }
47
+
48
+ /**
49
+ * Return filtered statement descriptor.
50
+ * This function should be used to filter statement description
51
+ * which was storing in stripe_statement_descriptor give setting prior to Giver 2.19.
52
+ *
53
+ * @since 2.19.1
54
+ * @deprecated
55
+ *
56
+ * @param string $text
57
+ *
58
+ * @return false|string
59
+ */
60
+ protected function filterOldStatementDescriptor($text)
61
+ {
62
+ $statementDescriptor = trim($text);
63
+ $unsupportedCharacters = ['<', '>', '"', '\''];
64
+ $statementDescriptor = str_replace($unsupportedCharacters, '', $statementDescriptor);
65
+ return substr($statementDescriptor, 0, 22);
66
+ }
67
  }
vendor/autoload.php CHANGED
@@ -4,4 +4,4 @@
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
- return ComposerAutoloaderInit5b9c1a06b1905cafb976b03a91a99973::getLoader();
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
+ return ComposerAutoloaderInit1fc5c821db983a586f37398682c5c64c::getLoader();
vendor/composer/autoload_real.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
- class ComposerAutoloaderInit5b9c1a06b1905cafb976b03a91a99973
6
  {
7
  private static $loader;
8
 
@@ -24,15 +24,15 @@ class ComposerAutoloaderInit5b9c1a06b1905cafb976b03a91a99973
24
 
25
  require __DIR__ . '/platform_check.php';
26
 
27
- spl_autoload_register(array('ComposerAutoloaderInit5b9c1a06b1905cafb976b03a91a99973', 'loadClassLoader'), true, true);
28
  self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
29
- spl_autoload_unregister(array('ComposerAutoloaderInit5b9c1a06b1905cafb976b03a91a99973', 'loadClassLoader'));
30
 
31
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
32
  if ($useStaticLoader) {
33
  require __DIR__ . '/autoload_static.php';
34
 
35
- call_user_func(\Composer\Autoload\ComposerStaticInit5b9c1a06b1905cafb976b03a91a99973::getInitializer($loader));
36
  } else {
37
  $map = require __DIR__ . '/autoload_namespaces.php';
38
  foreach ($map as $namespace => $path) {
@@ -53,12 +53,12 @@ class ComposerAutoloaderInit5b9c1a06b1905cafb976b03a91a99973
53
  $loader->register(true);
54
 
55
  if ($useStaticLoader) {
56
- $includeFiles = Composer\Autoload\ComposerStaticInit5b9c1a06b1905cafb976b03a91a99973::$files;
57
  } else {
58
  $includeFiles = require __DIR__ . '/autoload_files.php';
59
  }
60
  foreach ($includeFiles as $fileIdentifier => $file) {
61
- composerRequire5b9c1a06b1905cafb976b03a91a99973($fileIdentifier, $file);
62
  }
63
 
64
  return $loader;
@@ -70,7 +70,7 @@ class ComposerAutoloaderInit5b9c1a06b1905cafb976b03a91a99973
70
  * @param string $file
71
  * @return void
72
  */
73
- function composerRequire5b9c1a06b1905cafb976b03a91a99973($fileIdentifier, $file)
74
  {
75
  if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
76
  $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
+ class ComposerAutoloaderInit1fc5c821db983a586f37398682c5c64c
6
  {
7
  private static $loader;
8
 
24
 
25
  require __DIR__ . '/platform_check.php';
26
 
27
+ spl_autoload_register(array('ComposerAutoloaderInit1fc5c821db983a586f37398682c5c64c', 'loadClassLoader'), true, true);
28
  self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
29
+ spl_autoload_unregister(array('ComposerAutoloaderInit1fc5c821db983a586f37398682c5c64c', 'loadClassLoader'));
30
 
31
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
32
  if ($useStaticLoader) {
33
  require __DIR__ . '/autoload_static.php';
34
 
35
+ call_user_func(\Composer\Autoload\ComposerStaticInit1fc5c821db983a586f37398682c5c64c::getInitializer($loader));
36
  } else {
37
  $map = require __DIR__ . '/autoload_namespaces.php';
38
  foreach ($map as $namespace => $path) {
53
  $loader->register(true);
54
 
55
  if ($useStaticLoader) {
56
+ $includeFiles = Composer\Autoload\ComposerStaticInit1fc5c821db983a586f37398682c5c64c::$files;
57
  } else {
58
  $includeFiles = require __DIR__ . '/autoload_files.php';
59
  }
60
  foreach ($includeFiles as $fileIdentifier => $file) {
61
+ composerRequire1fc5c821db983a586f37398682c5c64c($fileIdentifier, $file);
62
  }
63
 
64
  return $loader;
70
  * @param string $file
71
  * @return void
72
  */
73
+ function composerRequire1fc5c821db983a586f37398682c5c64c($fileIdentifier, $file)
74
  {
75
  if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
76
  $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
vendor/composer/autoload_static.php CHANGED
@@ -4,7 +4,7 @@
4
 
5
  namespace Composer\Autoload;
6
 
7
- class ComposerStaticInit5b9c1a06b1905cafb976b03a91a99973
8
  {
9
  public static $files = array (
10
  '5255c38a0faeba867671b61dfda6d864' => __DIR__ . '/..' . '/paragonie/random_compat/lib/random.php',
@@ -125,9 +125,9 @@ class ComposerStaticInit5b9c1a06b1905cafb976b03a91a99973
125
  public static function getInitializer(ClassLoader $loader)
126
  {
127
  return \Closure::bind(function () use ($loader) {
128
- $loader->prefixLengthsPsr4 = ComposerStaticInit5b9c1a06b1905cafb976b03a91a99973::$prefixLengthsPsr4;
129
- $loader->prefixDirsPsr4 = ComposerStaticInit5b9c1a06b1905cafb976b03a91a99973::$prefixDirsPsr4;
130
- $loader->classMap = ComposerStaticInit5b9c1a06b1905cafb976b03a91a99973::$classMap;
131
 
132
  }, null, ClassLoader::class);
133
  }
4
 
5
  namespace Composer\Autoload;
6
 
7
+ class ComposerStaticInit1fc5c821db983a586f37398682c5c64c
8
  {
9
  public static $files = array (
10
  '5255c38a0faeba867671b61dfda6d864' => __DIR__ . '/..' . '/paragonie/random_compat/lib/random.php',
125
  public static function getInitializer(ClassLoader $loader)
126
  {
127
  return \Closure::bind(function () use ($loader) {
128
+ $loader->prefixLengthsPsr4 = ComposerStaticInit1fc5c821db983a586f37398682c5c64c::$prefixLengthsPsr4;
129
+ $loader->prefixDirsPsr4 = ComposerStaticInit1fc5c821db983a586f37398682c5c64c::$prefixDirsPsr4;
130
+ $loader->classMap = ComposerStaticInit1fc5c821db983a586f37398682c5c64c::$classMap;
131
 
132
  }, null, ClassLoader::class);
133
  }
vendor/composer/installed.php CHANGED
@@ -1,11 +1,11 @@
1
  <?php return array(
2
  'root' => array(
3
- 'pretty_version' => '1.9.0',
4
- 'version' => '1.9.0.0',
5
  'type' => 'wordpress-plugin',
6
  'install_path' => __DIR__ . '/../../',
7
  'aliases' => array(),
8
- 'reference' => 'b514780060730a8211486188b82fbbc4ea390c60',
9
  'name' => 'impress-org/give',
10
  'dev' => false,
11
  ),
@@ -41,12 +41,12 @@
41
  ),
42
  ),
43
  'impress-org/give' => array(
44
- 'pretty_version' => '1.9.0',
45
- 'version' => '1.9.0.0',
46
  'type' => 'wordpress-plugin',
47
  'install_path' => __DIR__ . '/../../',
48
  'aliases' => array(),
49
- 'reference' => 'b514780060730a8211486188b82fbbc4ea390c60',
50
  'dev_requirement' => false,
51
  ),
52
  'kjohnson/format-object-list' => array(
1
  <?php return array(
2
  'root' => array(
3
+ 'pretty_version' => '2.19.1',
4
+ 'version' => '2.19.1.0',
5
  'type' => 'wordpress-plugin',
6
  'install_path' => __DIR__ . '/../../',
7
  'aliases' => array(),
8
+ 'reference' => 'c1a2bd08dbb75fcca9b04076b188f12b71dd7807',
9
  'name' => 'impress-org/give',
10
  'dev' => false,
11
  ),
41
  ),
42
  ),
43
  'impress-org/give' => array(
44
+ 'pretty_version' => '2.19.1',
45
+ 'version' => '2.19.1.0',
46
  'type' => 'wordpress-plugin',
47
  'install_path' => __DIR__ . '/../../',
48
  'aliases' => array(),
49
+ 'reference' => 'c1a2bd08dbb75fcca9b04076b188f12b71dd7807',
50
  'dev_requirement' => false,
51
  ),
52
  'kjohnson/format-object-list' => array(