Tweak REST API context for secondary post types

This commit is contained in:
Brian Miyaji
2016-04-23 20:41:29 +10:00
parent e28b15556a
commit cbcda6bd4e
3 changed files with 5 additions and 5 deletions

View File

@@ -142,7 +142,7 @@ class SportsPress_Calendars {
'schema' => array(
'description' => __( 'Layout', 'sportspress' ),
'type' => 'string',
'context' => array( 'view', 'edit', 'embed' ),
'context' => array( 'view', 'edit' ),
'arg_options' => array(
'sanitize_callback' => 'rest_sanitize_request_arg',
),
@@ -157,7 +157,7 @@ class SportsPress_Calendars {
'schema' => array(
'description' => __( 'Events', 'sportspress' ),
'type' => 'array',
'context' => array( 'view', 'embed' ),
'context' => array( 'view' ),
'arg_options' => array(
'sanitize_callback' => 'rest_sanitize_request_arg',
),

View File

@@ -141,7 +141,7 @@ class SportsPress_League_Tables {
'schema' => array(
'description' => __( 'League Table', 'sportspress' ),
'type' => 'array',
'context' => array( 'view', 'edit', 'embed' ),
'context' => array( 'view', 'edit' ),
'arg_options' => array(
'sanitize_callback' => 'rest_sanitize_request_arg',
),

View File

@@ -142,7 +142,7 @@ class SportsPress_Player_Lists {
'schema' => array(
'description' => __( 'Layout', 'sportspress' ),
'type' => 'string',
'context' => array( 'view', 'edit', 'embed' ),
'context' => array( 'view', 'edit' ),
'arg_options' => array(
'sanitize_callback' => 'rest_sanitize_request_arg',
),
@@ -158,7 +158,7 @@ class SportsPress_Player_Lists {
'schema' => array(
'description' => __( 'Player List', 'sportspress' ),
'type' => 'array',
'context' => array( 'view', 'edit', 'embed' ),
'context' => array( 'view', 'edit' ),
'arg_options' => array(
'sanitize_callback' => 'rest_sanitize_request_arg',
),