Check the ‘meta’ value of a request is an associative array.
Parameters
$valuemixedrequired- The meta value submitted in the request.
$requestWP_REST_Requestrequired- Full details about the request.
$paramstringrequired- The parameter name.
Source
public function check_meta_is_array( $value, $request, $param ) {
if ( ! is_array( $value ) ) {
return false;
}
return $value;
}
Changelog
| Version | Description |
|---|---|
| 4.7.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.