Changeset 13275
- Timestamp:
- 03/05/2024 04:54:40 AM (17 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/shortcodes/class-readme-validator.php
r11381 r13275 21 21 $readme_contents = ''; 22 22 if ( ! empty( $_REQUEST['readme'] ) && is_string( $_REQUEST['readme'] ) ) { 23 $readme_url = $_REQUEST['readme'];23 $readme_url = wp_unslash( $_REQUEST['readme'] ); 24 24 } 25 25 if ( ! empty( $_POST['readme_contents'] ) && is_string( $_POST['readme_contents'] ) ) { 26 $readme_contents = base64_decode( wp_unslash( $_POST['readme_contents'] ) );26 $readme_contents = base64_decode( wp_unslash( $_POST['readme_contents'] ), true ); 27 27 } 28 28 ?> … … 68 68 69 69 } elseif ( ! empty( $_POST['readme_contents'] ) && is_string( $_POST['readme_contents'] ) ) { 70 $errors = Validator::instance()->validate_content( base64_decode( wp_unslash( $_REQUEST['readme_contents'] ) ) ); 70 $contents = base64_decode( wp_unslash( $_REQUEST['readme_contents'] ), true ); 71 if ( ! $contents ) { 72 return; 73 } 74 75 $errors = Validator::instance()->validate_content( $contents ); 71 76 72 77 } else {
Note: See TracChangeset
for help on using the changeset viewer.