# node_runtime: Improve proxy mapping \(\#41807\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/ba7ea71c00f228a2d7580c63ebc57305ed76342b)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: ba7ea71c00f228a2d7580c63ebc57305ed76342b

Requested commit: ba7ea71c00f228a2d7580c63ebc57305ed76342b

Commit: ba7ea71c00f228a2d7580c63ebc57305ed76342b

Tree: 7f7ed177ac7f0ea0f40747d8736a3e7719b44d79

Author: tidely

Committer: GitHub

## Message

```
node_runtime: Improve proxy mapping (#41807)

Closes #ISSUE

More accurately map localhost to `127.0.0.1`. Previously we would
lowercase and simply replace all instances of localhost inside of the
URL string, meaning query parameters, username, password etc. could not
contain the string `localhost` or contain uppercase letters without
getting modified. Added a test ensuring the mapping logic works. The
previous implementation would fail this new test.

Release Notes:

- Improved the behavior of mapping `localhost` to `127.0.0.1` when
passing configured proxy urls to `node`
```

## Parents

- [cd04450273bc43b1ac1879af930cfa272d46b798](https://git.cafe/gitcafe/zed/commit/cd04450273bc43b1ac1879af930cfa272d46b798?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/ba7ea71c00f228a2d7580c63ebc57305ed76342b?format=markdown)
