Skip to content
Snippets Groups Projects
Commit ec90ed3d authored by Kerri Miller's avatar Kerri Miller
Browse files

Use existing usage counter abstraction

parent 5d78044d
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -103,7 +103,7 @@ def after_update(issuable)
 
# Track edits to title or description
#
Gitlab::UsageDataCounters::MergeRequestActivityUniqueCounter
merge_request_activity_counter
.public_send("track_#{action}_edit_action".to_sym, user: current_user) # rubocop:disable GitlabSecurity/PublicSend
 
# Track changes to Draft/WIP status
Loading
Loading
@@ -116,12 +116,12 @@ def after_update(issuable)
if !old_title_wip && new_title_wip
# Marked as Draft/WIP
#
Gitlab::UsageDataCounters::MergeRequestActivityUniqueCounter
merge_request_activity_counter
.track_marked_as_draft_action(user: current_user)
elsif old_title_wip && !new_title_wip
# Unmarked as Draft/WIP
#
Gitlab::UsageDataCounters::MergeRequestActivityUniqueCounter
merge_request_activity_counter
.track_unmarked_as_draft_action(user: current_user)
end
end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment