summaryrefslogtreecommitdiff
path: root/app/workers/irker_worker.rb
diff options
context:
space:
mode:
authorPaco Guzman <pacoguzmanp@gmail.com>2016-07-26 09:21:42 +0200
committerPaco Guzman <pacoguzmanp@gmail.com>2016-08-03 07:00:20 +0200
commit8f359ea9170b984ad43d126e17628c31ac3a1f14 (patch)
treeee47d5172537ddedabc2cc38ef3cb5bf966c89ee /app/workers/irker_worker.rb
parentcd7c2cb6ddd4d9c9f9bdae00c887c0022c121c17 (diff)
downloadgitlab-ce-8f359ea9170b984ad43d126e17628c31ac3a1f14.tar.gz
Move to Gitlab::Diff::FileCollection
Instead calling diff_collection.count use diff_collection.size which is cache on the diff_collection
Diffstat (limited to 'app/workers/irker_worker.rb')
-rw-r--r--app/workers/irker_worker.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/workers/irker_worker.rb b/app/workers/irker_worker.rb
index 605ec4f04e5..a3c34e02baa 100644
--- a/app/workers/irker_worker.rb
+++ b/app/workers/irker_worker.rb
@@ -142,7 +142,7 @@ class IrkerWorker
def files_count(commit)
files = "#{commit.diffs.real_size} file"
- files += 's' if commit.diffs.count > 1
+ files += 's' if commit.diffs.size > 1
files
end