No need to specify port
It doesn't set headers after redirect

- `Error: Can't set headers after they are sent.`
Open/close connection properly