summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorRobert Schilling <rschilling@student.tugraz.at>2015-11-21 21:36:31 +0100
committerRobert Schilling <rschilling@student.tugraz.at>2015-11-21 21:36:31 +0100
commit26b12e2c374c8f07abda06a8b19bd116448325f4 (patch)
tree123d044cbb8c7a3f2bebdddcc859f79eada5c6e8 /lib
parent319808fc7be2886224541209eeae153d85386bd0 (diff)
downloadgitlab-ce-26b12e2c374c8f07abda06a8b19bd116448325f4.tar.gz
Add upvote/downvote fields to merge request and note API to preserve compatibilityfix-award-emoji-api
Diffstat (limited to 'lib')
-rw-r--r--lib/api/entities.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/api/entities.rb b/lib/api/entities.rb
index 3da6bc415d6..7f9dba4b6a5 100644
--- a/lib/api/entities.rb
+++ b/lib/api/entities.rb
@@ -163,6 +163,8 @@ module API
class MergeRequest < ProjectEntity
expose :target_branch, :source_branch
+ # deprecated, always returns 0
+ expose :upvotes, :downvotes
expose :author, :assignee, using: Entities::UserBasic
expose :source_project_id, :target_project_id
expose :label_names, as: :labels
@@ -192,6 +194,9 @@ module API
expose :author, using: Entities::UserBasic
expose :created_at
expose :system?, as: :system
+ # upvote? and downvote? are deprecated, always return false
+ expose :upvote?, as: :upvote
+ expose :downvote?, as: :downvote
end
class MRNote < Grape::Entity