Page MenuHomePhabricator

Trim and URI encode symbol names before building URIs from them
ClosedPublic

Authored by epriestley on Tue, Oct 29, 4:41 PM.

Details

Summary

Fixes T13437. This URI construction was just missing URI encoding.

Also, trim the symbol because my test case ended up catching "#define\n" as symbol text.

Test Plan
  • Configured a repository to have PHP symbols.
  • Touched a ".php" file with "#define" in it.
  • Diffed the change.
  • Command-clicked "#define" in the UI, in Safari/MacOS, to jump to the definition.
    • Before: taken to a nonsense page where "#define" became an anchor.
    • After: taken to symbol search for "#define".

Diff Detail

Repository
rP Phabricator
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

epriestley created this revision.Tue, Oct 29, 4:41 PM
epriestley requested review of this revision.Tue, Oct 29, 4:43 PM
This revision was not accepted when it landed; it landed in state Needs Review.Tue, Oct 29, 4:48 PM
This revision was automatically updated to reflect the committed changes.