Created
March 26, 2014 19:23
-
-
Save paulgibbs/9791193 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/bp-xprofile/bp-xprofile-filters.php b/bp-xprofile/bp-xprofile-filters.php | |
index cfac474..c049194 100644 | |
--- a/bp-xprofile/bp-xprofile-filters.php | |
+++ b/bp-xprofile/bp-xprofile-filters.php | |
@@ -73,8 +73,6 @@ function xprofile_filter_kses( $content ) { | |
} | |
/** | |
- * xprofile_sanitize_data_value_before_save ( $field_value, $field_id ) | |
- * | |
* Safely runs profile field data through kses and force_balance_tags. | |
* | |
* @param string $field_value | |
@@ -85,8 +83,9 @@ function xprofile_filter_kses( $content ) { | |
function xprofile_sanitize_data_value_before_save ( $field_value, $field_id, $reserialize = true ) { | |
// Return if empty | |
- if ( empty( $field_value ) ) | |
- return; | |
+ if ( empty( $field_value ) ) { | |
+ return $field_value; | |
+ } | |
// Value might be serialized | |
$field_value = maybe_unserialize( $field_value ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment