Skip to content

Commit

Permalink
Merge pull request #920 from carstingaxion/fix/fragment-of-752-allow-…
Browse files Browse the repository at this point in the history
…user-datetime-formats-to-contain-special-chars

Allow special chars in user-defined date- and time-format strings
  • Loading branch information
mauteri authored Sep 26, 2024
2 parents 3a1ee6b + c79ff78 commit 00db293
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions includes/core/classes/class-user.php
Original file line number Diff line number Diff line change
Expand Up @@ -214,8 +214,8 @@ public function save_profile_fields( int $user_id ): void {
}

update_user_meta( $user_id, 'gatherpress_event_updates_opt_in', intval( filter_input( INPUT_POST, 'gatherpress_event_updates_opt_in' ) ) );
update_user_meta( $user_id, 'gatherpress_date_format', sanitize_text_field( filter_input( INPUT_POST, 'gatherpress_date_format' ) ) );
update_user_meta( $user_id, 'gatherpress_time_format', sanitize_text_field( filter_input( INPUT_POST, 'gatherpress_time_format' ) ) );
update_user_meta( $user_id, 'gatherpress_date_format', sanitize_text_field( filter_input( INPUT_POST, 'gatherpress_date_format', FILTER_SANITIZE_ADD_SLASHES ) ) );
update_user_meta( $user_id, 'gatherpress_time_format', sanitize_text_field( filter_input( INPUT_POST, 'gatherpress_time_format', FILTER_SANITIZE_ADD_SLASHES ) ) );
update_user_meta( $user_id, 'gatherpress_timezone', sanitize_text_field( filter_input( INPUT_POST, 'gatherpress_timezone' ) ) );
}
}

0 comments on commit 00db293

Please sign in to comment.