diff --git a/README.md b/README.md index 78cb34c..045d2aa 100644 --- a/README.md +++ b/README.md @@ -103,6 +103,7 @@ You can create a very simple demo application like this: ```javascript var providerUri; +var opts = { client_uri: OAUTH3.utils.clientUri(window.location) }; // this is any OAuth3-compatible provider, such as oauth3.org @@ -110,7 +111,7 @@ var providerUri; // function onChangeProvider(_providerUri) { providerUri = _providerUri; - return OAUTH3.discover(providerUri); // just to cache + return OAUTH3.discover(providerUri, opts); // just to cache } @@ -118,7 +119,6 @@ function onChangeProvider(_providerUri) { // function onClickLogin() { - var opts = { client_uri: OAuth3.clientUri(window.location) }; return OAUTH3.implicitGrant(providerUri, opts).then(function (session) { console.info('Authentication was Successful:');