Use wiki.disk_path
This commit is contained in:
parent
e4b465d746
commit
314e5b5f20
4 changed files with 4 additions and 4 deletions
|
@ -51,7 +51,7 @@ module Projects
|
|||
end
|
||||
|
||||
def wiki_path
|
||||
repo_path + '.wiki'
|
||||
project.wiki.disk_path
|
||||
end
|
||||
|
||||
def trash_repositories!
|
||||
|
|
|
@ -74,7 +74,7 @@ module Github
|
|||
def fetch_wiki_repository
|
||||
return if project.wiki.repository_exists?
|
||||
|
||||
wiki_path = "#{project.disk_path}.wiki"
|
||||
wiki_path = project.wiki.disk_path
|
||||
gitlab_shell.import_repository(project.repository_storage_path, wiki_path, wiki_url)
|
||||
rescue Gitlab::Shell::Error => e
|
||||
# GitHub error message when the wiki repo has not been created,
|
||||
|
|
|
@ -8,7 +8,7 @@ module Gitlab
|
|||
end
|
||||
|
||||
def disk_path
|
||||
"#{project.disk_path}.wiki"
|
||||
project.wiki.disk_path
|
||||
end
|
||||
|
||||
def import_url
|
||||
|
|
|
@ -11,7 +11,7 @@ describe Gitlab::GithubImport::WikiFormatter do
|
|||
|
||||
describe '#disk_path' do
|
||||
it 'appends .wiki to project path' do
|
||||
expect(wiki.disk_path).to eq project.disk_path + '.wiki'
|
||||
expect(wiki.disk_path).to eq project.wiki.disk_path
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue