diff options
author | Timothy Andrew <mail@timothyandrew.net> | 2016-09-20 12:36:54 +0300 |
---|---|---|
committer | Timothy Andrew <mail@timothyandrew.net> | 2016-09-20 13:35:25 +0300 |
commit | 8957293d9bd0d711db3af26182205c2fe4125194 (patch) | |
tree | dcdd25393e2d6248971fddbd6c9eac30fe27ff6e /app/models/issue | |
parent | fa890604aaf15b9e4f0199e6a4cff24c29955a37 (diff) |
Implement review comments from @yorickpeterse
1. Change multiple updates to a single `update_all`
2. Use cascading deletes
3. Extract an average function for the database median.
4. Move database median to `lib/gitlab/database`
5. Use `delete_all` instead of `destroy_all`
6. Minor refactoring
Diffstat (limited to 'app/models/issue')
-rw-r--r-- | app/models/issue/metrics.rb | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/app/models/issue/metrics.rb b/app/models/issue/metrics.rb index 3c1fcea9e6f..4436696cc1a 100644 --- a/app/models/issue/metrics.rb +++ b/app/models/issue/metrics.rb @@ -13,10 +13,6 @@ class Issue::Metrics < ActiveRecord::Base self.save if self.changed? end - def record_commit_mention!(commit_time) - self.update(first_mentioned_in_commit_at: commit_time) if self.first_mentioned_in_commit_at.blank? - end - private def issue_assigned_to_list_label? |