PluginProbe
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) / 1.8.13
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) v1.8.13
1.8.13 1.8.12.3 1.8.12.2 1.8.12.1 1.8.12 1.8.11.3 1.8.11.2 1.8.11.1 1.8.11 1.6.6 1.6.60 1.6.7 1.6.8 1.6.9 1.7.0 1.7.0.1 1.7.0.11 1.7.0.12 1.7.0.14 1.7.0.2 1.7.0.3 1.7.0.5 1.7.0.6 1.7.0.7 1.7.0.9 All 211 releases
← All changes | includes/currency/class-charitable-currency.php +7 -2 1.7.0.2 → 1.8.13 View file →
@@ -3,9 +3,9 @@
3 3 * Charitable Currency helper.
4 4 *
5 5 * @package Charitable/Classes/Charitable_Currency
6 6 * @author David Bisset
7 - * @copyright Copyright (c) 2022, WP Charitable LLC
7 + * @copyright Copyright (c) 2023, WP Charitable LLC
8 8 * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
9 9 * @since 1.0.0
10 10 * @version 1.6.55
11 11 */
@@ -202,8 +202,13 @@
202 202 * @param string $amount The amount to be cast to decimal format.
203 203 * @return string
204 204 */
205 205 public function cast_to_decimal_format( $amount ) {
206 +
207 + if ( is_wp_error( $amount ) ) {
208 + return $amount;
209 + }
210 +
206 211 if ( $this->is_comma_decimal() ) {
207 212 $amount = str_replace( ',', '.', $amount );
208 213 } else {
209 214 $amount = str_replace( ',', '', $amount );
@@ -375,9 +380,9 @@
375 380 $this->get_currency_symbol( 'CNY' )
376 381 ),
377 382 'COP' => sprintf(
378 383 /* translators: %s: currency symbol */
379 - __( 'Colombian Peso (%s', 'charitable' ),
384 + __( 'Colombian Peso (%s)', 'charitable' ),
380 385 $this->get_currency_symbol( 'COP' )
381 386 ),
382 387 'CZK' => sprintf(
383 388 /* translators: %s: currency symbol */