diff --git a/src/MusicStore/Views/Shared/_LoginPartial.cshtml b/src/MusicStore/Views/Shared/_LoginPartial.cshtml index b539905a3b..6abadf073f 100644 --- a/src/MusicStore/Views/Shared/_LoginPartial.cshtml +++ b/src/MusicStore/Views/Shared/_LoginPartial.cshtml @@ -2,31 +2,28 @@ @if (User.IsSignedIn()) { - //Either NTLM will be used or social authentication will be used. Based on the authentication schemes enabled remove an unused block. - if (User.Identity.AuthenticationType != "NTLM") + using (Html.BeginForm("LogOff", "Account", FormMethod.Post, new { id = "logoutForm", @class = "navbar-right" })) { - using (Html.BeginForm("LogOff", "Account", FormMethod.Post, new { id = "logoutForm", @class = "navbar-right" })) - { - @Html.AntiForgeryToken() + @Html.AntiForgeryToken() -
- } - } - else - { - //This code block necessary only for NTLM authentication } } +//Either NTLM will be used or social authentication will be used. Based on the authentication schemes enabled remove an unused block. +else if (User.Identity.IsAuthenticated && User.Identity.AuthenticationType == "NTLM") +{ + //This code block necessary only for NTLM authentication + +} else {