Skip to content

Commit 9e85449

Browse files
committed
Don't try and validation JSON Types
1 parent 4b24ab1 commit 9e85449

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Exceptionless.Web/Utility/AutoValidationActionFilter.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ public async Task OnActionExecutionAsync(ActionExecutingContext context, ActionE
3131
if (parameter.Name == null || !context.ActionArguments.TryGetValue(parameter.Name, out object? subject) || subject is null)
3232
continue;
3333

34+
// We don't support validating JSON Types
35+
if (subject is Newtonsoft.Json.Linq.JToken)
36+
continue;
37+
3438
(bool isValid, var errors) = await MiniValidator.TryValidateAsync(subject, _serviceProvider, recurse: true);
3539
if (isValid)
3640
continue;

0 commit comments

Comments
 (0)