]> source.dussan.org Git - gitblit.git/commitdiff
Fixed cache bug wrt create/edit repository with existing repo name (issue-172)
authorJames Moger <james.moger@gitblit.com>
Fri, 21 Dec 2012 21:49:04 +0000 (16:49 -0500)
committerJames Moger <james.moger@gitblit.com>
Fri, 21 Dec 2012 21:49:04 +0000 (16:49 -0500)
src/com/gitblit/GitBlit.java

index 782da63e9a7d431d393c3ad6e9e11ebc2a8dcab3..54ca6d2056eed36bd3f8a608b91d0e887014af40 100644 (file)
@@ -1937,7 +1937,7 @@ public class GitBlit implements ServletContextListener {
                        if (!repository.name.toLowerCase().endsWith(org.eclipse.jgit.lib.Constants.DOT_GIT_EXT)) {\r
                                repository.name += org.eclipse.jgit.lib.Constants.DOT_GIT_EXT;\r
                        }\r
-                       if (new File(repositoriesFolder, repository.name).exists()) {\r
+                       if (hasRepository(repository.name)) {\r
                                throw new GitBlitException(MessageFormat.format(\r
                                                "Can not create repository ''{0}'' because it already exists.",\r
                                                repository.name));\r