diff --git "a/src/Coldairarrow.Api/00Filter/\346\216\245\345\217\243\350\257\267\346\261\202\346\227\245\345\277\227/ApiLogAttribute.cs" "b/src/Coldairarrow.Api/00Filter/\346\216\245\345\217\243\350\257\267\346\261\202\346\227\245\345\277\227/ApiLogAttribute.cs" index 594dfef4..3cf006a3 100644 --- "a/src/Coldairarrow.Api/00Filter/\346\216\245\345\217\243\350\257\267\346\261\202\346\227\245\345\277\227/ApiLogAttribute.cs" +++ "b/src/Coldairarrow.Api/00Filter/\346\216\245\345\217\243\350\257\267\346\261\202\346\227\245\345\277\227/ApiLogAttribute.cs" @@ -35,6 +35,9 @@ public void OnActionExecuted(ActionExecutedContext filterContext) _requesTime.TryRemove(HttpContextCore.Current, out _); var request = filterContext.HttpContext.Request; + string contentType = request.ContentType ?? string.Empty; + if (!contentType.Contains("json")) + return; string resContent = string.Empty; if (filterContext.Result is ContentResult result) resContent = result.Content;