Skip to content

Commit 67dcc97

Browse files
committed
Rename hxxp to isHttp
1 parent 0152fb9 commit 67dcc97

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/node/app/proxy.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -168,15 +168,15 @@ export class ProxyHttpProvider extends HttpProvider implements HttpProxyProvider
168168
// the event.
169169
;(request as Request).base = base
170170

171-
const hxxp = response instanceof http.ServerResponse
171+
const isHttp = response instanceof http.ServerResponse
172172
const path = base ? route.fullPath.replace(base, "") : route.fullPath
173173
const options: proxy.ServerOptions = {
174174
changeOrigin: true,
175175
ignorePath: true,
176-
target: `${hxxp ? "http" : "ws"}://127.0.0.1:${port}${path}${
176+
target: `${isHttp ? "http" : "ws"}://127.0.0.1:${port}${path}${
177177
Object.keys(route.query).length > 0 ? `?${querystring.stringify(route.query)}` : ""
178178
}`,
179-
ws: !hxxp,
179+
ws: !isHttp,
180180
}
181181

182182
if (response instanceof http.ServerResponse) {

0 commit comments

Comments
 (0)