Can you access the file mentioned? if so, have you verified if all the commas and parenthesis are correct? If else I might not know.
I do have access to the specific file and the code that has the error is the specific one as below:
/**
* Retrieves the item's schema for display / public consumption purposes.
*
* @since 4.7.0
*
* @return array Public item schema data.
*/
public function get_public_item_schema() {
$schema = $this->get_item_schema();
foreach ( $schema['properties'] as &$property ) {
unset( $property['arg_options'] );
}
return $schema;
}
The second line with the schema variable.
I am sure that many other people are facing this issue but nobody realised it.
Can at least somebody help with this issue? The theme developers are even bothered answering???
Hello,
Can you please mention on which file you are seeing it? Please share the full path of the file.
Hi there,
Sorry, but i do not want to share the website name that is shown on the path.
Warning: Invalid argument supplied for foreach() in /wp-includes/rest-api/endpoints/class-wp-rest-controller.php on line 295
This is where i am getting the error…..Any ideas what is causing it?