Page MenuHomePhabricator

Provide a more informative alternative to 404 on invalid shortened Phurl URL
ClosedPublic

Authored by lpriestley on Nov 9 2015, 10:37 PM.
Tags
None
Referenced Files
F13291059: D14450.id.diff
Tue, Jun 4, 9:05 PM
F13290428: D14450.id34945.diff
Tue, Jun 4, 6:13 PM
F13290427: D14450.id34944.diff
Tue, Jun 4, 6:13 PM
F13290426: D14450.id34931.diff
Tue, Jun 4, 6:13 PM
F13290424: D14450.diff
Tue, Jun 4, 6:13 PM
F13286223: D14450.diff
Tue, Jun 4, 6:50 AM
F13253032: D14450.diff
Sat, May 25, 2:19 AM
F13239457: D14450.id34931.diff
Wed, May 22, 3:11 AM
Subscribers

Details

Summary

When accessing an invalid URL on the short Phurl domain, users should see informative message

Test Plan

Open URL in the previously configured Phurl short domain such as https://www.zz.us and see dialog with message. Open https://www.zz.us/u/123 for a valid U123 Phurl and access destination URL.

Diff Detail

Repository
rP Phabricator
Branch
phurlshortdomaininvalidmessage
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 8755
Build 10183: Run Core Tests
Build 10182: arc lint + arc unit

Event Timeline

lpriestley retitled this revision from to Provide a more informative alternative to 404 on invalid shortened Phurl URL.
lpriestley updated this object.
lpriestley edited the test plan for this revision. (Show Details)
lpriestley added a reviewer: epriestley.
epriestley edited edge metadata.

Very minor, but we should probably set the HTTP response code to 404 on these. You should be able to do something like this:

$dialog = $this->newDialog()
  ->...

return id(new AphrontDialogResponse())
  ->setDialog($dialog)
  ->setResponseCode(404);
This revision is now accepted and ready to land.Nov 9 2015, 10:40 PM
lpriestley edited edge metadata.

Setting http response code on 'invalid url' dialog

This revision was automatically updated to reflect the committed changes.