From 07795cfed510078ff9139d14b60e505b1f2a31a5 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sun, 8 Mar 2015 09:12:18 +0000 Subject: [PATCH] Code cleanup. git-svn-id: http://svn.redmine.org/redmine/trunk@14055 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/models/repository.rb | 4 ---- app/models/repository/git.rb | 6 ++++++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/app/models/repository.rb b/app/models/repository.rb index 21e97bb6e..475445ae5 100644 --- a/app/models/repository.rb +++ b/app/models/repository.rb @@ -501,9 +501,5 @@ class Repository < ActiveRecord::Base self.class.connection.delete("DELETE FROM #{ci} WHERE #{ci}.changeset_id IN (SELECT #{cs}.id FROM #{cs} WHERE #{cs}.repository_id = #{id})") self.class.connection.delete("DELETE FROM #{cp} WHERE #{cp}.changeset_id IN (SELECT #{cs}.id FROM #{cs} WHERE #{cs}.repository_id = #{id})") self.class.connection.delete("DELETE FROM #{cs} WHERE #{cs}.repository_id = #{id}") - clear_extra_info_of_changesets - end - - def clear_extra_info_of_changesets end end diff --git a/app/models/repository/git.rb b/app/models/repository/git.rb index 18797315f..9b77dca8b 100644 --- a/app/models/repository/git.rb +++ b/app/models/repository/git.rb @@ -254,4 +254,10 @@ class Repository::Git < Repository self.save end private :clear_extra_info_of_changesets + + def clear_changesets + super + clear_extra_info_of_changesets + end + private :clear_changesets end -- 2.39.5