From c4af00a99bd2e579c3f591481213e7d858d60765 Mon Sep 17 00:00:00 2001 From: "Kyle J. McKay" Date: Wed, 7 Aug 2013 10:30:25 -0700 Subject: [PATCH] Project.pm: allow _new for all does_exist projects The valid_name check is more restrictive than the does_exist check which prevents loading some projects that actually exist (e.g. a fork that has been kept but has had its forkee removed). If the project actually does_exist go ahead and allow the _new to succeed. --- Girocco/Project.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Girocco/Project.pm b/Girocco/Project.pm index ce926f1..1208c59 100644 --- a/Girocco/Project.pm +++ b/Girocco/Project.pm @@ -306,7 +306,7 @@ sub _hooks_install { sub _new { my $class = shift; my ($name, $base_path, $path) = @_; - valid_name($name) or die "refusing to create project with invalid name ($name)!"; + does_exist($name,1) || valid_name($name) or die "refusing to create project with invalid name ($name)!"; $path ||= "$base_path/$name.git"; my $proj = { name => $name, base_path => $base_path, path => $path }; -- 2.11.4.GIT