Commit 896c3a0a9d4c9ccdfab275d772ae5991dd92865e
1 parent
5c649266
Exists in
master
and in
4 other branches
remove update_repository calls
Showing
4 changed files
with
0 additions
and
24 deletions
Show diff stats
app/models/namespace.rb
| ... | ... | @@ -27,7 +27,6 @@ class Namespace < ActiveRecord::Base |
| 27 | 27 | |
| 28 | 28 | after_create :ensure_dir_exist |
| 29 | 29 | after_update :move_dir |
| 30 | - after_commit :update_gitolite, on: :update, if: :require_update_gitolite | |
| 31 | 30 | after_destroy :rm_dir |
| 32 | 31 | |
| 33 | 32 | scope :root, where('type IS NULL') |
| ... | ... | @@ -89,11 +88,6 @@ class Namespace < ActiveRecord::Base |
| 89 | 88 | end |
| 90 | 89 | end |
| 91 | 90 | |
| 92 | - def update_gitolite | |
| 93 | - @require_update_gitolite = false | |
| 94 | - projects.each(&:update_repository) | |
| 95 | - end | |
| 96 | - | |
| 97 | 91 | def rm_dir |
| 98 | 92 | dir_path = File.join(Gitlab.config.gitolite.repos_path, path) |
| 99 | 93 | FileUtils.rm_r( dir_path, force: true ) | ... | ... |
app/models/project_team.rb
app/models/protected_branch.rb
| ... | ... | @@ -18,13 +18,6 @@ class ProtectedBranch < ActiveRecord::Base |
| 18 | 18 | validates :name, presence: true |
| 19 | 19 | validates :project, presence: true |
| 20 | 20 | |
| 21 | - after_save :update_repository | |
| 22 | - after_destroy :update_repository | |
| 23 | - | |
| 24 | - def update_repository | |
| 25 | - project.update_repository | |
| 26 | - end | |
| 27 | - | |
| 28 | 21 | def commit |
| 29 | 22 | project.repository.commit(self.name) |
| 30 | 23 | end | ... | ... |
app/models/users_project.rb
| ... | ... | @@ -81,11 +81,6 @@ class UsersProject < ActiveRecord::Base |
| 81 | 81 | end |
| 82 | 82 | end |
| 83 | 83 | |
| 84 | - GitoliteWorker.perform_async( | |
| 85 | - :update_repositories, | |
| 86 | - project_ids | |
| 87 | - ) | |
| 88 | - | |
| 89 | 84 | true |
| 90 | 85 | rescue |
| 91 | 86 | false |
| ... | ... | @@ -100,11 +95,6 @@ class UsersProject < ActiveRecord::Base |
| 100 | 95 | end |
| 101 | 96 | end |
| 102 | 97 | |
| 103 | - GitoliteWorker.perform_async( | |
| 104 | - :update_repositories, | |
| 105 | - project_ids | |
| 106 | - ) | |
| 107 | - | |
| 108 | 98 | true |
| 109 | 99 | rescue |
| 110 | 100 | false | ... | ... |