Use object instead of array to retain team IDs when updating event results via API

This commit is contained in:
Brian Miyaji
2021-03-18 13:58:02 +09:00
parent 9e4709048e
commit 842e3ce7e8

View File

@@ -223,7 +223,7 @@ class SP_REST_API {
'update_callback' => 'SP_REST_API::update_post_meta_arrays',
'schema' => array(
'description' => __( 'Results', 'sportspress' ),
'type' => 'array',
'type' => 'object',
'context' => array( 'view', 'edit' ),
'arg_options' => array(
'sanitize_callback' => 'rest_sanitize_request_arg',