Browse Source
Merge pull request #21463 from abpframework/AuditingInterceptor
Skip to write audit logs if `auditLogInfo.HttpMethod` is `GET/Head`.
pull/21465/head
SALİH ÖZKARA
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
3 additions and
1 deletions
-
framework/src/Volo.Abp.Auditing/Volo/Abp/Auditing/AuditingInterceptor.cs
|
|
|
@ -191,7 +191,9 @@ public class AuditingInterceptor : AbpInterceptor, ITransientDependency |
|
|
|
} |
|
|
|
|
|
|
|
if (!options.IsEnabledForGetRequests && |
|
|
|
invocation.Method.Name.StartsWith("Get", StringComparison.OrdinalIgnoreCase)) |
|
|
|
(string.Equals(auditLogInfo.HttpMethod, "Get", StringComparison.OrdinalIgnoreCase) || |
|
|
|
string.Equals(auditLogInfo.HttpMethod, "Head", StringComparison.OrdinalIgnoreCase) || |
|
|
|
invocation.Method.Name.StartsWith("Get", StringComparison.OrdinalIgnoreCase))) |
|
|
|
{ |
|
|
|
return false; |
|
|
|
} |
|
|
|
|