diff --git a/packages/dev-middleware/src/inspector-proxy/InspectorProxy.js b/packages/dev-middleware/src/inspector-proxy/InspectorProxy.js index 0cfb55a05ff1ec..2fd08a01a7e883 100644 --- a/packages/dev-middleware/src/inspector-proxy/InspectorProxy.js +++ b/packages/dev-middleware/src/inspector-proxy/InspectorProxy.js @@ -94,12 +94,13 @@ export default class InspectorProxy implements InspectorProxyQueries { response: ServerResponse, next: (?Error) => mixed, ) { + const pathname = url.parse(request.url).pathname; if ( - request.url === PAGES_LIST_JSON_URL || - request.url === PAGES_LIST_JSON_URL_2 + pathname === PAGES_LIST_JSON_URL || + pathname === PAGES_LIST_JSON_URL_2 ) { this._sendJsonResponse(response, this.getPageDescriptions()); - } else if (request.url === PAGES_LIST_JSON_VERSION_URL) { + } else if (pathname === PAGES_LIST_JSON_VERSION_URL) { this._sendJsonResponse(response, { Browser: 'Mobile JavaScript', 'Protocol-Version': '1.1',