1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-18 21:02:41 +01:00

Use a stricter regexp in Diffusion remarkup

Summary:
Just minor bookkeeping, but the current regexp is too liberal and
will match things which can't possibly be revision hashes.

Test Plan:
Typed things which should and shouldn't be revision links, they
got handled properly.

Reviewed By: aran
Reviewers: jungejason, tuomaspelkonen, aran
CC: aran
Differential Revision: 185
This commit is contained in:
epriestley 2011-04-29 20:11:12 -07:00
parent 5da364f8f9
commit 79d037fe66

View file

@ -24,7 +24,7 @@ class PhabricatorRemarkupRuleDiffusion
public function apply($text) {
return preg_replace_callback(
'@\br([A-Z]+[a-z0-9]+)\b@',
'@\br([A-Z]+[a-f0-9]+)\b@',
array($this, 'markupDiffusionLink'),
$text);
}