handle nested search in hash and discover as index.html

This commit is contained in:
AJ ONeal 2017-02-06 14:41:25 -07:00
parent 4e225e95c9
commit 2d10171de7
1 changed files with 7 additions and 1 deletions

View File

@ -42,6 +42,12 @@
if (-1 !== ['#', '?'].indexOf(search[0])) {
search = search.substring(1);
}
// Solve for case of search within hash
// example: #/authorization_dialog/?state=...&redirect_uri=...
var queryIndex = search.indexOf('?');
if (-1 !== queryIndex) {
search = search.substr(queryIndex + 1);
}
var args = search.split('&');
var argsParsed = {};
@ -88,7 +94,7 @@
};
var result = {
url: providerUri + '/.well-known/oauth3/directives.html#' + core.querystringify(params)
url: providerUri + '/.well-known/oauth3/#/?' + core.querystringify(params)
, state: params.state
, method: 'GET'
, query: params