Reputation: 956
I need to handle request with certain url and im trying to do it like this:
await page.route("**/api/common/v1/play?**", handle_data_route)
But it also handles a url like this: api/common/v1/play_random?
Upvotes: 0
Views: 1923
Reputation: 1509
Try using a regular expression instead
await page.route(/^.*\/api\/common\/v1\/play\?.*$/, handle_data_route)
Upvotes: 0