OSDN Git Service

Bug#326: Always empty repositories if trailing slash is missed in base_path
authorValery Sizov <vsv2711@gmail.com>
Tue, 14 Feb 2012 22:42:46 +0000 (00:42 +0200)
committerValery Sizov <vsv2711@gmail.com>
Tue, 14 Feb 2012 22:43:13 +0000 (00:43 +0200)
app/models/repository.rb

index f4fdfe5..8f9f974 100644 (file)
@@ -56,7 +56,7 @@ class Repository
   end
 
   def path_to_repo
-    GIT_HOST["base_path"] + path + ".git"
+    File.join(GIT_HOST["base_path"], "#{path}.git")
   end
 
   def update_repository