Welcome to mirror list, hosted at ThFree Co, Russian Federation.

destroy_service.rb « issuable « services « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 4c64655a622f2ef404d000604b08538981c13979 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# frozen_string_literal: true

module Issuable
  class DestroyService < IssuableBaseService
    def execute(issuable)
      TodoService.new.destroy_target(issuable) do |issuable|
        if issuable.destroy
          issuable.update_project_counter_caches
          issuable.assignees.each(&:invalidate_cache_counts)
        end
      end
    end
  end
end