This commit is contained in:
2023-02-05 11:35:05 -06:00
parent f7cbb48cc2
commit d5a186379d
4 changed files with 3 additions and 6 deletions

View File

@@ -59,7 +59,7 @@ public class UserController : ControllerBase
/// <returns></returns> /// <returns></returns>
[AllowAnonymous] [AllowAnonymous]
[HttpGet("LoginAsGuest")] [HttpGet("LoginAsGuest")]
public async Task<IActionResult> GuestLogin([FromQuery] string returnUrl) public async Task<IActionResult> GuestLogin([FromQuery] string? returnUrl)
{ {
var principal = await this.claimsTransformation.CreateClaimsFromGuestPrincipal(User); var principal = await this.claimsTransformation.CreateClaimsFromGuestPrincipal(User);
if (principal != null) if (principal != null)

View File

@@ -43,7 +43,7 @@ namespace Shogi.Api
app.UseWhen( app.UseWhen(
// Log anything that isn't related to swagger. // Log anything that isn't related to swagger.
context => ShouldLog(context), context => IsNotSwaggerUI(context),
appBuilder => appBuilder.UseHttpLogging()); appBuilder => appBuilder.UseHttpLogging());
// Configure the HTTP request pipeline. // Configure the HTTP request pipeline.
@@ -69,7 +69,7 @@ namespace Shogi.Api
app.Run(); app.Run();
static bool ShouldLog(HttpContext context) static bool IsNotSwaggerUI(HttpContext context)
{ {
var path = context.Request.GetEncodedPathAndQuery(); var path = context.Request.GetEncodedPathAndQuery();

View File

@@ -1,2 +0,0 @@
CREATE TYPE [session].[JsonDocument]
FROM NVARCHAR(max) NOT NULL

View File

@@ -76,7 +76,6 @@
<Build Include="User\Tables\User.sql" /> <Build Include="User\Tables\User.sql" />
<Build Include="Session\Types\SessionName.sql" /> <Build Include="Session\Types\SessionName.sql" />
<Build Include="User\Types\UserName.sql" /> <Build Include="User\Types\UserName.sql" />
<Build Include="Session\Types\JsonDocument.sql" />
<Build Include="User\StoredProcedures\CreateUser.sql" /> <Build Include="User\StoredProcedures\CreateUser.sql" />
<Build Include="Session\Stored Procedures\ReadSessionPlayerCount.sql" /> <Build Include="Session\Stored Procedures\ReadSessionPlayerCount.sql" />
<Build Include="User\StoredProcedures\ReadUser.sql" /> <Build Include="User\StoredProcedures\ReadUser.sql" />