summaryrefslogtreecommitdiff
path: root/app/controllers/concerns
diff options
context:
space:
mode:
authorDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-09-01 19:12:05 -0300
committerDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-09-08 15:50:07 -0300
commitd86c6666623a90d46fa4cfe624c67e86c6ad235f (patch)
treec3290abd871d37f2addb0794b6f526fc31e9d66c /app/controllers/concerns
parent796bdf1dcb86b5e77fc054208afc632f75518605 (diff)
downloadgitlab-ce-d86c6666623a90d46fa4cfe624c67e86c6ad235f.tar.gz
Refresh todos count cache when an Issue/MR is deleted
Diffstat (limited to 'app/controllers/concerns')
-rw-r--r--app/controllers/concerns/issuable_actions.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/controllers/concerns/issuable_actions.rb b/app/controllers/concerns/issuable_actions.rb
index 77b4efffd7f..bb32bc502e6 100644
--- a/app/controllers/concerns/issuable_actions.rb
+++ b/app/controllers/concerns/issuable_actions.rb
@@ -8,6 +8,8 @@ module IssuableActions
def destroy
issuable.destroy
+ destroy_method = "destroy_#{issuable.class.name.underscore}".to_sym
+ TodoService.new.public_send(destroy_method, issuable, current_user)
name = issuable.class.name.titleize.downcase
flash[:notice] = "The #{name} was successfully deleted."