Page MenuHomePhabricator

Add an alias to Phurl URL's
ClosedPublic

Authored by lpriestley on Nov 3 2015, 6:43 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Sep 2, 1:00 PM
Unknown Object (File)
Sun, Sep 1, 10:09 PM
Unknown Object (File)
Sat, Aug 31, 4:23 AM
Unknown Object (File)
Mon, Aug 19, 9:00 PM
Unknown Object (File)
Mon, Aug 19, 5:09 PM
Unknown Object (File)
Mon, Aug 19, 2:26 PM
Unknown Object (File)
Sun, Aug 18, 12:25 AM
Unknown Object (File)
Sat, Aug 17, 4:31 AM

Details

Summary

Ref T8992, Add an alias to Phurl URL's that can be used to redirect to link.

Test Plan

Add an alias to Phurl object, and navigate to local.install.com/u/<newalias>. This should redirect to the Phurl's URL.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

lpriestley retitled this revision from to Add an alias to Phurl URL's.
lpriestley updated this object.
lpriestley edited the test plan for this revision. (Show Details)
lpriestley added a reviewer: epriestley.
epriestley edited edge metadata.
epriestley added inline comments.
src/applications/phurl/controller/PhabricatorPhurlURLAccessController.php
12–20

Indents a little weird?

src/applications/phurl/editor/PhabricatorPhurlURLEditor.php
130

These null should be $xaction, I think.

136

Consider describing permitted characters instead ("...may only contain letters, numbers, hyphens and underscores") so users don't have to guess what "special characters" means.

139

This allows aliases like "--a--a--" and "I_-_-__--" but I suppose those are totally fine.

This revision is now accepted and ready to land.Nov 3 2015, 6:54 PM
lpriestley marked 4 inline comments as done.
lpriestley edited edge metadata.

Updating regex to not allow hyphens and underscores

src/applications/phurl/editor/PhabricatorPhurlURLEditor.php
139

I actually don't think we should accept those.

joshuaspence added inline comments.
src/applications/phurl/application/PhabricatorPhurlApplication.php
33

Hmm, technically /u/(?P<id>[1-9]\d*) will match against this regex as well?

This revision was automatically updated to reflect the committed changes.