diff --git a/common/ASC.Api.Core/Security/InvitationLinkHelper.cs b/common/ASC.Api.Core/Security/InvitationLinkHelper.cs index 8747572584c..04b577a18d6 100644 --- a/common/ASC.Api.Core/Security/InvitationLinkHelper.cs +++ b/common/ASC.Api.Core/Security/InvitationLinkHelper.cs @@ -191,5 +191,6 @@ static file class Queries public static readonly Func> AuditEventsAsync = EF.CompileAsyncQuery( (MessagesContext ctx, int tenantId, string target, string description) => - ctx.AuditEvents.FirstOrDefault(a => a.TenantId == tenantId && a.Target == target && a.DescriptionRaw == description)); + ctx.AuditEvents.FirstOrDefault(a => + a.TenantId == tenantId && a.Action == (int)MessageAction.RoomInviteLinkUsed && a.Target == target && a.DescriptionRaw == description)); } \ No newline at end of file