From ce054e404db82d33d8925fb15547fa44eebf24d9 Mon Sep 17 00:00:00 2001 From: Marco Dinis Date: Tue, 3 Dec 2024 08:41:06 +0000 Subject: [PATCH] Fix UsageEvent for UserTaskState changed (#49409) It was using the TaskType in the IssueType field. --- lib/auth/usertasks/usertasksv1/service.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/auth/usertasks/usertasksv1/service.go b/lib/auth/usertasks/usertasksv1/service.go index c20d745d05a9b..5a1e388150dd2 100644 --- a/lib/auth/usertasks/usertasksv1/service.go +++ b/lib/auth/usertasks/usertasksv1/service.go @@ -160,7 +160,7 @@ func (s *Service) emitCreateAuditEvent(ctx context.Context, req *usertasksv1.Use func userTaskToUserTaskStateEvent(ut *usertasksv1.UserTask) *usagereporter.UserTaskStateEvent { ret := &usagereporter.UserTaskStateEvent{ TaskType: ut.GetSpec().GetTaskType(), - IssueType: ut.GetSpec().GetTaskType(), + IssueType: ut.GetSpec().GetIssueType(), State: ut.GetSpec().GetState(), } if ut.GetSpec().GetTaskType() == usertasks.TaskTypeDiscoverEC2 {