Use string constants for refs/*, refs/heads/, refs/tags/

These are fairly well-known strings, used often enough in the code,
so use constants that correspond to them.

Change-Id: I00bc6a2034ab3041816b6cc1492b7f2117d1952f
Signed-off-by: Shawn O. Pearce <sop@google.com>
This commit is contained in:
Shawn O. Pearce
2010-04-20 18:24:28 -07:00
parent f7fed45d45
commit 93951e0e13
6 changed files with 21 additions and 16 deletions

View File

@@ -115,8 +115,8 @@ final class AdminCreateProject extends BaseCommand {
final Project.NameKey newProjectNameKey = new Project.NameKey(projectName);
final RefRight.Key prk =
new RefRight.Key(newProjectNameKey, new RefRight.RefPattern("refs/*"),
ApprovalCategory.OWN, ownerId);
new RefRight.Key(newProjectNameKey, new RefRight.RefPattern(
RefRight.ALL), ApprovalCategory.OWN, ownerId);
final RefRight pr = new RefRight(prk);
pr.setMaxValue((short) 1);
pr.setMinValue((short) 1);