Repository navigation
v0.2.2 — Redirects on the PHP development server
Fixes redirects emitted by PHP's built-in development server.
redirect() constructed responses with the protocol version hard-coded to 2. The response emitter wrote that into the status line, so the HTTP/1.x development server sent an invalid HTTP/2 302 Found response that HTTP clients could reject. refresh() inherited the same problem because it uses redirect().
Redirects now use the same response factory as other responses, with its HTTP/1.1 default. The response also gets the correct reason phrase for its status — for example, See Other for a 303 redirect. The requested status and Location header are preserved, and the body is empty.
Regression tests cover the protocol version, destination, empty body and status-specific reason phrase, including the protocol returned by refresh().
The package README now points to the central NAF documentation, and an unused legacy logo has been removed.