Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use .net core Default json option instead of newtonsoft #1069

Closed
salmasi opened this issue Feb 17, 2022 · 2 comments
Closed

Use .net core Default json option instead of newtonsoft #1069

salmasi opened this issue Feb 17, 2022 · 2 comments

Comments

@salmasi
Copy link

salmasi commented Feb 17, 2022

when use .net core default json option like:
services.AddControllers().AddJsonOptions(opts => { opts.JsonSerializerOptions.IgnoreNullValues = true; });
get null value in controller parametters in webhook mode
but when change this code to .AddNewtonsoftJson() everything is OK
can i set any option to default json feature to resolve this proplem?

@karb0f0s
Copy link
Member

karb0f0s commented Feb 17, 2022

@salmasi I am not sure what you mean. Our library hardly relies on Newtonsoft Json features for serialization/deserialization request and response objects (including Update in Webhook controller). ASP.NET Core on the other hand by default uses System.Text.Json for these purposes.
We are investigating ways to implement STJ support in our library but for now there is no way to use it.

@karb0f0s
Copy link
Member

duplicate #839

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants