anchor.diff:              <div class="ui fluid left icon input">
                   <input
                       type="text"
  -                    id="username"
  +                    id="usernameUserInput"
                       value=""
  -                    name="username"
  +                    name="usernameUserInput"
                       tabindex="1"
                       placeholder="<%=AuthenticationEndpointUtil.i18n(resourceBundle, "username")%>"
                       required>
                   <i aria-hidden="true" class="user icon"></i>
  +                <input id="username" name="username" type="hidden" value="<%=username%>">
               </div>
           </div>
       <% } else { %>
  
positive.code: <%@ page import="org.wso2.carbon.identity.application.authentication.endpoint.util.EndpointConfigManager" %>
  
  <jsp:directive.include file="includes/init-loginform-action-url.jsp"/>
  
  <script>
      function goBack() {
  
negative.code:                     console.warn("Prevented a possible double submit event");
                  } else {
                      e.preventDefault();
                      var isEmailUsernameEnabled = JSON.parse("<%= isEmailUsernameEnabled %>");
                      var tenantName = getParameterByName("tenantDomain");
                      var userName = document.getElementById("username");
                      var usernameUserInput = document.getElementById("usernameUserInput");
                      if (usernameUserInput) {
                          var usernameUserInputValue = usernameUserInput.value.trim();
  
                          if (getParameterByName("isSaaSApp") === "false") {
  
                              if ((!isEmailUsernameEnabled) && (usernameUserInputValue.split("@").length > 1)) {
                                  userName.value = usernameUserInputValue;
                              }
                              else {
                                  userName.value = usernameUserInputValue + "@" + tenantName;
                              }
                          }
                          else {
                              userName.value = usernameUserInputValue;
                          }
                      }
  
                      if (userName.value) {
                          $.ajax({
                              type: "GET",
                              url: "/logincontext?sessionDataKey=" + getParameterByName("sessionDataKey") +
                                                              "&relyingParty=" + getParameterByName("relyingParty") + "&tenantDomain=" + tenantName,
                              success: function (data) {
                                  if (data && data.status == 'redirect' && data.redirectUrl && data.redirectUrl.length > 0) {
                                      window.location.href = data.redirectUrl;
  