Page MenuHomePhabricator

When users visit a Phame post URI with an old blog ID, canonicalize the URI instead of 404'ing
ClosedPublic

Authored by epriestley on Jul 31 2019, 6:40 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Jun 20, 12:43 PM
Unknown Object (File)
Thu, Jun 5, 4:38 PM
Unknown Object (File)
May 10 2025, 3:45 AM
Unknown Object (File)
May 6 2025, 5:45 PM
Unknown Object (File)
Apr 20 2025, 11:43 AM
Unknown Object (File)
Apr 13 2025, 7:53 AM
Unknown Object (File)
Apr 12 2025, 9:30 PM
Unknown Object (File)
Apr 10 2025, 5:13 PM
Subscribers
None
Tokens
"Orange Medal" token, awarded by Krinkle.

Details

Summary

Fixes T13353. If you:

  • Visit a blog post and save the URI.
  • Move the blog post to a different blog.
  • Revisit the old URI.

...we currently 404. We know what you're trying to do and should just redirect you to the new URI instead. We already do this if you visit a URI with a noncanonical slug.

Test Plan
  • Created post A.
  • Copied the live URI.
  • Moved it to a different blog.
  • Visited the saved URI from the earlier step.
  • Before: 404.
  • After: Redirect to the canonical URI.

Diff Detail

Repository
rP Phabricator
Branch
phameredir1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 23205
Build 31874: Run Core Tests
Build 31873: arc lint + arc unit