diff options
author | Douwe Maan <douwe@gitlab.com> | 2015-12-07 12:03:34 +0100 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2015-12-07 12:03:34 +0100 |
commit | 0bca65b28344cfb4f4a6577c32b448268e7d9465 (patch) | |
tree | 682ed6bb606f2a45c9a333e921ad68b387852b62 /lib/api/entities.rb | |
parent | dbbd2b863b402e460ac1dc90f852fcae617a2351 (diff) | |
parent | 234f4bf20fb338f2164976fd39203fbc671afd29 (diff) | |
download | gitlab-ce-0bca65b28344cfb4f4a6577c32b448268e7d9465.tar.gz |
Merge branch 'master' into gsmethells/gitlab-ce-sort-by-due-dategsmethells/gitlab-ce-sort-by-due-date
Diffstat (limited to 'lib/api/entities.rb')
-rw-r--r-- | lib/api/entities.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/api/entities.rb b/lib/api/entities.rb index 9f337bc3cc6..96b73df6af9 100644 --- a/lib/api/entities.rb +++ b/lib/api/entities.rb @@ -194,6 +194,7 @@ module API expose :author, using: Entities::UserBasic expose :created_at expose :system?, as: :system + expose :noteable_id, :noteable_type # upvote? and downvote? are deprecated, always return false expose :upvote?, as: :upvote expose :downvote?, as: :downvote @@ -224,6 +225,8 @@ module API expose :target_id, :target_type, :author_id expose :data, :target_title expose :created_at + expose :note, using: Entities::Note, if: ->(event, options) { event.note? } + expose :author, using: Entities::UserBasic, if: ->(event, options) { event.author } expose :author_username do |event, options| if event.author |