Compare commits
2 Commits
7d2d27c609
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| 48a1d6f984 | |||
| 79090e91d6 |
@@ -1,9 +1,7 @@
|
||||
using AS1024.CommunityDocumentationPage.Interfaces;
|
||||
using AS1024.CommunityDocumentationPage.Models;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using Newtonsoft.Json;
|
||||
using System.Net.Http.Headers;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Text.Json;
|
||||
|
||||
namespace AS1024.CommunityDocumentationPage.DIScopes
|
||||
{
|
||||
@@ -25,7 +23,8 @@ namespace AS1024.CommunityDocumentationPage.DIScopes
|
||||
HttpResponseMessage result = await client.GetAsync(BuildNetBoxURI());
|
||||
string stringResult = await result.Content.ReadAsStringAsync();
|
||||
#pragma warning disable CS8603 // Possible null reference return.
|
||||
return JsonConvert.DeserializeObject<RouteTargets>(stringResult);
|
||||
return JsonSerializer.Deserialize<RouteTargets>(stringResult,
|
||||
new JsonSerializerOptions { PropertyNamingPolicy = JsonNamingPolicy.SnakeCaseLower });
|
||||
#pragma warning restore CS8603 // Possible null reference return.
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user