summaryrefslogtreecommitdiff
path: root/app/serializers/note_entity.rb
diff options
context:
space:
mode:
authorJarka Kadlecova <jarka@gitlab.com>2017-08-11 18:48:06 +0200
committerJarka Kadlecova <jarka@gitlab.com>2017-08-11 18:48:06 +0200
commitd78037c246d14817937abbc4369e30ae12b022bc (patch)
treefca9b9516c635b30167ffd2614e6f51160b88ee4 /app/serializers/note_entity.rb
parent345df20870b718daa74c0177221c00cdec6083f3 (diff)
downloadgitlab-ce-d78037c246d14817937abbc4369e30ae12b022bc.tar.gz
Use UserNoteEntity instead of UserEntity for notes
Diffstat (limited to 'app/serializers/note_entity.rb')
-rw-r--r--app/serializers/note_entity.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/serializers/note_entity.rb b/app/serializers/note_entity.rb
index f84343aa71a..e5295f5f34d 100644
--- a/app/serializers/note_entity.rb
+++ b/app/serializers/note_entity.rb
@@ -3,7 +3,7 @@ class NoteEntity < API::Entities::Note
expose :type
- expose :author, using: UserEntity
+ expose :author, using: UserNoteEntity
expose :human_access do |note|
note.project.team.human_max_access(note.author_id)
@@ -15,7 +15,7 @@ class NoteEntity < API::Entities::Note
expose :redacted_note_html, as: :note_html
expose :last_edited_at, if: -> (note, _) { note.is_edited? }
- expose :last_edited_by, using: UserEntity, if: -> (note, _) { note.is_edited? }
+ expose :last_edited_by, using: UserNoteEntity, if: -> (note, _) { note.is_edited? }
expose :current_user do
expose :can_edit do |note|