Remove the Project#repo method
This commit is contained in:
parent
1e950e3148
commit
176b60d110
|
@ -353,7 +353,7 @@ class ProjectsController < Projects::ApplicationController
|
|||
end
|
||||
|
||||
def repo_exists?
|
||||
project.repository_exists? && !project.empty_repo? && project.repo
|
||||
project.repository_exists? && !project.empty_repo?
|
||||
|
||||
rescue Gitlab::Git::Repository::NoRepository
|
||||
project.repository.expire_exists_cache
|
||||
|
|
|
@ -992,10 +992,6 @@ class Project < ActiveRecord::Base
|
|||
false
|
||||
end
|
||||
|
||||
def repo
|
||||
repository.rugged
|
||||
end
|
||||
|
||||
def url_to_repo
|
||||
gitlab_shell.url_to_repo(full_path)
|
||||
end
|
||||
|
@ -1438,7 +1434,7 @@ class Project < ActiveRecord::Base
|
|||
# We'd need to keep track of project full path otherwise directory tree
|
||||
# created with hashed storage enabled cannot be usefully imported using
|
||||
# the import rake task.
|
||||
repo.config['gitlab.fullpath'] = gl_full_path
|
||||
repository.rugged.config['gitlab.fullpath'] = gl_full_path
|
||||
rescue Gitlab::Git::Repository::NoRepository => e
|
||||
Rails.logger.error("Error writing to .git/config for project #{full_path} (#{id}): #{e.message}.")
|
||||
nil
|
||||
|
|
Loading…
Reference in New Issue