Changeset 30944
- Timestamp:
- 12/16/2014 10:38:52 PM (10 years ago)
- Location:
- trunk/src/wp-admin/includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/plugin-install.php
r30889 r30944 29 29 function plugins_api($action, $args = null) { 30 30 31 if ( is_array($args) ) 32 $args = (object)$args; 33 34 if ( !isset($args->per_page) ) 31 if ( is_array( $args ) ) { 32 $args = (object) $args; 33 } 34 35 if ( ! isset( $args->per_page ) ) { 35 36 $args->per_page = 24; 37 } 38 39 if ( ! isset( $args->locale ) ) { 40 $args->locale = get_locale(); 41 } 36 42 37 43 /** -
trunk/src/wp-admin/includes/theme.php
r30697 r30944 315 315 * @return mixed 316 316 */ 317 function themes_api( $action, $args = null ) { 318 319 if ( is_array($args) ) 320 $args = (object)$args; 321 322 if ( !isset($args->per_page) ) 317 function themes_api( $action, $args = null ) { 318 319 if ( is_array( $args ) ) { 320 $args = (object) $args; 321 } 322 323 if ( ! isset( $args->per_page ) ) { 323 324 $args->per_page = 24; 325 } 326 327 if ( ! isset( $args->locale ) ) { 328 $args->locale = get_locale(); 329 } 330 324 331 /** 325 332 * Filter arguments used to query for installer pages from the WordPress.org Themes API. … … 332 339 * @param string $action Requested action. Likely values are 'theme_information', 333 340 * 'feature_list', or 'query_themes'. 334 341 */ 335 342 $args = apply_filters( 'themes_api_args', $args, $action ); 336 343
Note: See TracChangeset
for help on using the changeset viewer.