1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-09-20 01:08:50 +02:00

Disallow "{", "}" and "#" in Project monograms

Summary: Currently, mentioning two projects in a block (`{#a} {#b}`) produces an overzealous parse. Forbid these characters in project monograms.

Test Plan: Got correct markup.

Reviewers: btrahan, dctrwatson, chad

Reviewed By: chad

CC: aran

Differential Revision: https://secure.phabricator.com/D8141
This commit is contained in:
epriestley 2014-02-05 11:03:00 -08:00
parent 0726411cb4
commit 980f06f3da

View file

@ -45,7 +45,7 @@ final class PhabricatorProjectPHIDTypeProject extends PhabricatorPHIDType {
// NOTE: This explicitly does not match strings which contain only
// digits, because digit strings like "#123" are used to reference tasks at
// Facebook and are somewhat conventional in general.
return '[^\s.!,:;]*[^\s\d.!,:;]+[^\s.!,:;]*';
return '[^\s.!,:;{}#]*[^\s\d.!,:;{}#]+[^\s.!,:;{}#]*';
}
public function canLoadNamedObject($name) {