Changeset 57804
- Timestamp:
- 03/11/2024 11:14:26 PM (5 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-font-faces-controller.php
r57740 r57804 875 875 $overrides = array( 876 876 'upload_error_handler' => array( $this, 'handle_font_file_upload_error' ), 877 // Arbitrary string to avoid the is_uploaded_file() check applied878 // when using 'wp_handle_upload'.879 'action' => 'wp_handle_font_upload',880 877 // Not testing a form submission. 881 878 'test_form' => false, 882 // Seems mime type for files that are not images cannot be tested.883 // See wp_check_filetype_and_ext().884 'test_type' => true,885 879 // Only allow uploading font files for this request. 886 880 'mimes' => WP_Font_Utils::get_allowed_font_mime_types(), 887 881 ); 882 883 884 885 886 888 887 889 888 $uploaded_file = wp_handle_upload( $file, $overrides );
Note: See TracChangeset
for help on using the changeset viewer.