Class: Issues::RelatedBranchesService

Inherits:
BaseService show all
Defined in:
app/services/issues/related_branches_service.rb

Constant Summary

Constants inherited from BaseService

BaseService::NO_REBALANCING_NEEDED

Constants included from Gitlab::Utils::UsageData

Gitlab::Utils::UsageData::FALLBACK

Instance Attribute Summary

Attributes inherited from BaseService

#current_user, #params, #project

Instance Method Summary collapse

Methods inherited from BaseService

#close_service, #hook_data, #rebalance_if_needed, #reopen_service

Methods included from IncidentManagement::UsageData

#track_event, #track_incident_action

Methods included from Gitlab::Utils::UsageData

#alt_usage_data, #count, #distinct_count, #measure_duration, #redis_usage_data, #track_usage_event, #with_finished_at, #with_prometheus_client

Methods inherited from BaseService

#initialize

Methods included from BaseServiceUtility

#deny_visibility_level, #event_service, #log_error, #log_info, #notification_service, #system_hook_service, #todo_service, #visibility_level

Methods included from Gitlab::Allowable

#can?

Instance Method Details

#execute(issue) ⇒ Object


7
8
9
10
# File 'app/services/issues/related_branches_service.rb', line 7

def execute(issue)
  branch_names = branches_with_iid_of(issue) - branches_with_merge_request_for(issue)
  branch_names.map { |branch_name| branch_data(branch_name) }
end