thebatclaudio / wp-rest-api-v2-menus

Adding menus endpoints on WP REST API v2
47 stars 22 forks source link

Endpoints break from v0.3.1 -> v0.3.2 #11

Closed mantagen closed 5 years ago

mantagen commented 5 years ago

Version 0.3.1 of this plugin is working fine, but after an automatic update (to 0.3.2), all menus endpoints respond with:

<b>Warning</b>:  Invalid argument supplied for foreach() in <b>/home/mantagen/example/wp-includes/rest-api.php</b> on line <b>612</b><br />
{"term_id":5,
...
}

in plain text.

Any ideas which changes from 0.3.1 -> 0.3.2 could be causing this?

I'm getting the error in wp 4.8 up to 5

[I've edited the question after a few experiments]

mantagen commented 5 years ago

Closing this issue as I've seen that it was a problem with WP REST API cache not emptying after the plugin update. For some reason this caused this error. Having manually emptied the cache, all versions work fine!