- Timestamp:
- 07/15/2019 06:24:08 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/class-wp-rest-request.php
r45304 r45639 295 295 * @since 4.4.0 296 296 * 297 * @return array Map containing 'value' and 'parameters' keys. 297 * @return array|null Map containing 'value' and 'parameters' keys 298 * or null when no valid content-type header was 299 * available. 298 300 */ 299 301 public function get_content_type() { … … 335 337 336 338 $content_type = $this->get_content_type(); 337 if ( $content_type['value'] === 'application/json') {339 if ( isset( $content_type['value'] ) && 'application/json' === $content_type['value'] ) { 338 340 $order[] = 'JSON'; 339 341 }
Note: See TracChangeset
for help on using the changeset viewer.