Skip to content

Commit

Permalink
chore: add proper sanitization for input value
Browse files Browse the repository at this point in the history
  • Loading branch information
amiut committed May 13, 2024
1 parent afc4941 commit 58633c6
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ public function validate(TermMetaField ...$termMetaFields): ?WP_Error
continue;
}

// phpcs:ignore WordPressVIPMinimum.Security.PHPFilterFunctions.MissingThirdParameter
$postedValue = filter_input(
INPUT_POST,
$termMetaField->key(),
FILTER_SANITIZE_SPECIAL_CHARS
);

$sanitizedValue = (string) $termMetaField->sanitize($postedValue);
Expand Down

0 comments on commit 58633c6

Please sign in to comment.