2018-07-19 18:43:13 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2020-12-04 03:09:49 +00:00
|
|
|
class MergeRequestUserEntity < ::API::Entities::UserBasic
|
2021-01-28 18:09:27 +00:00
|
|
|
include UserStatusTooltip
|
|
|
|
|
2020-12-04 03:09:49 +00:00
|
|
|
expose :can_merge do |reviewer, options|
|
|
|
|
options[:merge_request]&.can_be_merged_by?(reviewer)
|
2018-06-21 12:22:40 +00:00
|
|
|
end
|
|
|
|
end
|
2020-12-04 03:09:49 +00:00
|
|
|
|
|
|
|
MergeRequestUserEntity.prepend_if_ee('EE::MergeRequestUserEntity')
|