Page MenuHomePhabricator

Implement HTTP response messages
ClosedPublic

Authored by joshuaspence on Apr 6 2015, 12:53 PM.
Tags
None
Referenced Files
F14762171: D12299.diff
Thu, Jan 23, 4:59 AM
Unknown Object (File)
Sun, Jan 19, 11:25 PM
Unknown Object (File)
Sat, Jan 18, 12:15 PM
Unknown Object (File)
Sat, Jan 18, 2:13 AM
Unknown Object (File)
Wed, Jan 15, 10:43 AM
Unknown Object (File)
Sun, Jan 12, 2:15 AM
Unknown Object (File)
Sat, Jan 11, 1:30 PM
Unknown Object (File)
Wed, Jan 8, 5:15 AM
Subscribers

Details

Summary

Fixes T7486. Implement HTTP response messages such as 200 OK and 404 Not Found. The status codes were taken from http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html.

Test Plan

Navigated to /foo and saw the response showing 404 Not Found in the Network tab of Chrome.

Diff Detail

Repository
rP Phabricator
Branch
master
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 5166
Build 5184: [Placeholder Plan] Wait for 30 Seconds

Event Timeline

joshuaspence retitled this revision from to Implement HTTP response messages.
joshuaspence updated this object.
joshuaspence edited the test plan for this revision. (Show Details)
joshuaspence added a reviewer: epriestley.
epriestley edited edge metadata.
epriestley added inline comments.
src/aphront/response/AphrontResponse.php
126

Maybe this should return "Status Unknown" or similar?

In the spirit of the project, I also recommend inclusion of 418.

This revision is now accepted and ready to land.Apr 6 2015, 1:04 PM
src/aphront/response/AphrontResponse.php
126

I actually disagree. I think that if we don't know the status message then we should leave it blank. This might allow the client to figure out the status message based on the response code (which Chrome seems to be able to do to some extent, because we have until now been returning 200 instead of 200 OK).

This revision was automatically updated to reflect the committed changes.