WP-API / docs

The content for developer.wordpress.org/rest-api
https://developer.wordpress.org/rest-api
110 stars 615 forks source link

Update themes.md #107

Open fabioquarantini opened 3 years ago

fabioquarantini commented 3 years ago

Status value is "active" and not "1". See "class-wp-rest-themes-controller.php" (Ln 91):

if ( isset( $registered['status'], $request['status'] ) && in_array( 'active', $request['status'], true ) ) { $active_theme = wp_get_theme(); $active_theme = $this->prepare_item_for_response( $active_theme, $request ); $themes[] = $this->prepare_response_for_collection( $active_theme ); }

kadamwhite commented 1 year ago

Thanks for this PR. The /reference/ folder is auto-generated from the schema, so we'll need to look at why the value came through this way, rather than simply correcting the generated file -- otherwise this will be wiped out the next time the reference documentation is updated.