better solution for #3027

This commit is contained in:
Dmitriy Zaporozhets 2013-03-05 17:06:22 +02:00
parent d5663e148f
commit 9ba21dd0c4

View file

@ -137,7 +137,7 @@ class Repository
file_path = File.join(storage_path, self.path_with_namespace, file_name) file_path = File.join(storage_path, self.path_with_namespace, file_name)
# Put files into a directory before archiving # Put files into a directory before archiving
prefix = self.path_with_namespace + "/" prefix = File.basename(self.path_with_namespace) + "/"
# Create file if not exists # Create file if not exists
unless File.exists?(file_path) unless File.exists?(file_path)