Ticket #45420: 45420.diff
File 45420.diff, 652 bytes (added by , 6 years ago) |
---|
-
src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php
174 174 175 175 // Include admin function to get access to wp_generate_attachment_metadata(). 176 176 require_once ABSPATH . 'wp-admin/includes/media.php'; 177 require_once ABSPATH . 'wp-admin/includes/image.php';178 177 179 178 wp_update_attachment_metadata( $id, wp_generate_attachment_metadata( $id, $file ) ); 180 179