Skip to content

Improve detection of REST requests #91

@bobbingwide

Description

@bobbingwide

In Gutenberg 8.4.0 there are a number of requests which are not being traced as REST requests since the URL form is not recognised. The Block directory search is one of them.

Here's the trace output showing that wp-json/wp/v2/blocks is detected but not /wp-json/__experimental/block-directory/search, which is used twice the first time a search is performed.

/wp-json/wp/v2/blocks?per_page=100&_locale=user,,1.488032,7.3.8,1291,4780,743,31,1016,50,30,14,55,0.15688490867615,C:/apache/htdocs/wp-a2z/bwtrace/bwtrace.rest.4,189,0,21364,127.0.0.1,1.485162,2020-07-06T07:46:42+00:00,Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML; like Gecko) Chrome/83.0.4103.116 Safari/537.36,GET
/wp-json/__experimental/block-directory/search?_locale=user,,0.917202,7.3.8,1291,4648,675,31,936,50,30,14,26,,,,,11713,127.0.0.1,0.913878,2020-07-06T07:47:03+00:00,Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML; like Gecko) Chrome/83.0.4103.116 Safari/537.36,OPTIONS
/wp-json/__experimental/block-directory/search?term=bea&_locale=user,,1.540149,7.3.8,1291,4657,684,31,947,50,30,14,26,,,,,11805,127.0.0.1,1.534153,2020-07-06T07:47:04+00:00,Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML; like Gecko) Chrome/83.0.4103.116 Safari/537.36,GET

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions