Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJarka Kadlecová <jarka@gitlab.com>2018-02-13 15:41:35 +0300
committerJarka Kadlecová <jarka@gitlab.com>2018-02-14 11:00:26 +0300
commitb0b4ae1875529cd7ca786bd5eccd49be9a40a038 (patch)
treee431498a102e05c4371d5be4e2430b91df01cb16 /app/models/commit.rb
parentbf5e617a10e8df48ff78442f42f2cd6e47f59072 (diff)
API - Include project in commits&blobs search results
Diffstat (limited to 'app/models/commit.rb')
-rw-r--r--app/models/commit.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/commit.rb b/app/models/commit.rb
index 2d2d89af030..8c960389652 100644
--- a/app/models/commit.rb
+++ b/app/models/commit.rb
@@ -116,6 +116,10 @@ class Commit
raw.id
end
+ def project_id
+ project.id
+ end
+
def ==(other)
other.is_a?(self.class) && raw == other.raw
end