Skip to content

Commit

Permalink
Merge pull request DuendeSoftware#895 from DuendeSoftware/brock/clien…
Browse files Browse the repository at this point in the history
…t-errors

fix sample client compliation errors
  • Loading branch information
leastprivilege authored May 20, 2022
2 parents 2b8e8cf + 013e151 commit 6f2cfe8
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System.Text.Json;
using System.Net.Http;
using System.Threading.Tasks;

Expand All @@ -27,7 +27,7 @@ public async Task<IActionResult> CallApi()
var client = _httpClientFactory.CreateClient("client");

var response = await client.GetStringAsync("identity");
ViewBag.Json = JArray.Parse(response).ToString();
ViewBag.Json = JsonDocument.Parse(response).ToString();

return View();
}
Expand Down
6 changes: 3 additions & 3 deletions clients/src/MvcJarJwt/Controllers/HomeController.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System.Text.Json;
using System.Net.Http;
using System.Threading.Tasks;

Expand All @@ -27,7 +27,7 @@ public async Task<IActionResult> CallApi()
var client = _httpClientFactory.CreateClient("client");

var response = await client.GetStringAsync("identity");
ViewBag.Json = JArray.Parse(response).ToString();
ViewBag.Json = JsonDocument.Parse(response).ToString();

return View();
}
Expand Down
6 changes: 3 additions & 3 deletions clients/src/MvcJarUriJwt/Controllers/HomeController.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System.Text.Json;
using System.Net.Http;
using System.Threading.Tasks;

Expand All @@ -27,7 +27,7 @@ public async Task<IActionResult> CallApi()
var client = _httpClientFactory.CreateClient("client");

var response = await client.GetStringAsync("identity");
ViewBag.Json = JArray.Parse(response).ToString();
ViewBag.Json = JsonDocument.Parse(response).ToString();

return View();
}
Expand Down

0 comments on commit 6f2cfe8

Please sign in to comment.