Changeset 43834
- Timestamp:
- 10/29/2018 12:47:01 AM (6 years ago)
- Location:
- branches/5.0/src/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/5.0/src/wp-includes/rest-api.php
r43833 r43834 1369 1369 $server = rest_get_server(); 1370 1370 $data = (array) $response->get_data(); 1371 if ( method_exists( $server, 'get_compact_response_links' ) ) { 1372 $links = call_user_func( array( $server, 'get_compact_response_links' ), $response ); 1373 } else { 1374 $links = call_user_func( array( $server, 'get_response_links' ), $response ); 1375 } 1371 $links = $server->get_compact_response_links( $response ); 1376 1372 if ( ! empty( $links ) ) { 1377 1373 $data['_links'] = $links; -
branches/5.0/src/wp-includes/rest-api/endpoints/class-wp-rest-controller.php
r43736 r43834 213 213 $data = (array) $response->get_data(); 214 214 $server = rest_get_server(); 215 216 if ( method_exists( $server, 'get_compact_response_links' ) ) { 217 $links = call_user_func( array( $server, 'get_compact_response_links' ), $response ); 218 } else { 219 $links = call_user_func( array( $server, 'get_response_links' ), $response ); 220 } 215 $links = $server->get_compact_response_links( $response ); 221 216 222 217 if ( ! empty( $links ) ) {
Note: See TracChangeset
for help on using the changeset viewer.