Skip to content

Commit

Permalink
Strip slashes when saving features. Fixes #2731.
Browse files Browse the repository at this point in the history
  • Loading branch information
JakePT committed May 11, 2022
1 parent 8fc0cd5 commit 183b86a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions includes/dashboard.php
Original file line number Diff line number Diff line change
Expand Up @@ -421,6 +421,8 @@ function action_wp_ajax_ep_cancel_index() {
* @since 2.2
*/
function action_wp_ajax_ep_save_feature() {
$_POST = wp_unslash( $_POST );

if ( empty( $_POST['feature'] ) || empty( $_POST['settings'] ) || ! check_ajax_referer( 'ep_dashboard_nonce', 'nonce', false ) ) {
wp_send_json_error();
exit;
Expand Down

0 comments on commit 183b86a

Please sign in to comment.