Skip to content

Commit

Permalink
Merge pull request CMB2#1015 from wearerequired/fix/1014-unslash-money
Browse files Browse the repository at this point in the history
Restore `wp_unslash()` for money values
  • Loading branch information
jtsternberg authored Aug 17, 2017
2 parents 5a590e6 + db19826 commit 8ac74c2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions includes/CMB2_Sanitize.php
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,8 @@ public function text_money() {

$search = array( $wp_locale->number_format['thousands_sep'], $wp_locale->number_format['decimal_point'] );
$replace = array( '', '.' );

$this->value = wp_unslash( $this->value ); // Strip slashes. Example: 2\'180.00.

// for repeatable
if ( is_array( $this->value ) ) {
Expand Down

0 comments on commit 8ac74c2

Please sign in to comment.