summaryrefslogtreecommitdiff
path: root/lib/gitlab/bare_repository_import/repository.rb
diff options
context:
space:
mode:
authorjerasmus <jerasmus@gitlab.com>2018-10-15 12:42:24 +0200
committerjerasmus <jerasmus@gitlab.com>2018-10-15 12:42:24 +0200
commit58f29d5f855ea2e1411b99804a74710483a13f90 (patch)
tree0b06ecd3c0bb1bcf3d3c6660c2bc49eefaff08b2 /lib/gitlab/bare_repository_import/repository.rb
parent0572da24c990fc01d88acfbd32728221e3e3a711 (diff)
parenta9827357186e38e5732d8dae23d9d02b1f4c7218 (diff)
downloadgitlab-ce-58f29d5f855ea2e1411b99804a74710483a13f90.tar.gz
Merge branch 'master' into 48746-fix-files-uploaded-in-base6448746-fix-files-uploaded-in-base64
Diffstat (limited to 'lib/gitlab/bare_repository_import/repository.rb')
-rw-r--r--lib/gitlab/bare_repository_import/repository.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/gitlab/bare_repository_import/repository.rb b/lib/gitlab/bare_repository_import/repository.rb
index c0c666dfb7b..b903c581aac 100644
--- a/lib/gitlab/bare_repository_import/repository.rb
+++ b/lib/gitlab/bare_repository_import/repository.rb
@@ -1,3 +1,5 @@
+# frozen_string_literal: true
+
module Gitlab
module BareRepositoryImport
class Repository
@@ -6,9 +8,12 @@ module Gitlab
attr_reader :group_path, :project_name, :repo_path
def initialize(root_path, repo_path)
+ unless root_path.ends_with?('/')
+ root_path = "#{root_path}/"
+ end
+
@root_path = root_path
@repo_path = repo_path
- @root_path << '/' unless root_path.ends_with?('/')
full_path =
if hashed? && !wiki?