Skip to content

Commit

Permalink
Merge pull request #4101 from sallakarppinen/issue-4092
Browse files Browse the repository at this point in the history
Hides the Sign in-button on 401 page
  • Loading branch information
nicolaasmatthijs committed May 27, 2016
2 parents 206d949 + 6b8b0f9 commit b78760b
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions shared/oae/api/oae.api.authentication.js
Expand Up @@ -237,7 +237,11 @@ define(['exports', 'jquery', 'oae.api.config', 'oae.api.i18n', 'oae.api.user', '

// Use the `auth.html` `authExternalButton` macro to create a form that performs this
// authentication
var $template = $('<div class="hide">${authExternalButton(strategy, opts)}</div>');
var $template = $('<div><!--'
+ '<div class="hide" id="oae-auth-external">'
+ '${authExternalButton(strategy, opts)}'
+ '</div>'
+ '--></div>');
var form = utilAPI.template().render($template, {
'strategy': strategyInfo.enabledExternalStrategies[strategyId],
'opts': {
Expand All @@ -249,7 +253,8 @@ define(['exports', 'jquery', 'oae.api.config', 'oae.api.i18n', 'oae.api.user', '
});

// Submit the form
$($.trim(form)).appendTo('body').submit();
$($.trim(form)).appendTo('body');
$('#oae-auth-external').find('.btn-external-auth').click();
};

/**
Expand Down

0 comments on commit b78760b

Please sign in to comment.