Skip to content

Commit

Permalink
chore: add comment and fix typo (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
gao-sun authored Sep 13, 2023
1 parent 4016b38 commit 3d32682
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions sample-mvc/Controllers/HomeController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ public IActionResult SignIn()
return Challenge(new AuthenticationProperties { RedirectUri = "/" });
}

// Use the `new` keyword to avoid conflict with the `ControllerBase.SignOut` method
new public IActionResult SignOut()
{
return SignOut(new AuthenticationProperties { RedirectUri = "/" });
Expand Down
4 changes: 2 additions & 2 deletions src/Logto.AspNetCore.Authentication/docs/tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,9 @@ Then, add the links to your View:
<p>Is authenticated: @User.Identity?.IsAuthenticated</p>
@if (User.Identity?.IsAuthenticated == true)
{
<a asp-controller="Home" asp-action="SignOut">Sign out</a>
<a asp-controller="Home" asp-action="SignOut">Sign out</a>
} else {
<a asp-controller="Home" asp-action="SignIn">Sign in</a>
<a asp-controller="Home" asp-action="SignIn">Sign in</a>
}
```

Expand Down

0 comments on commit 3d32682

Please sign in to comment.