diff options
Diffstat (limited to 'examples/consumer')
-rw-r--r-- | examples/consumer/common.php | 6 | ||||
-rw-r--r-- | examples/consumer/try_auth.php | 5 |
2 files changed, 8 insertions, 3 deletions
diff --git a/examples/consumer/common.php b/examples/consumer/common.php index 5e63fce..67f4273 100644 --- a/examples/consumer/common.php +++ b/examples/consumer/common.php @@ -58,8 +58,9 @@ function &getStore() { " Please check the effective permissions."; exit(0); } + $r = new Auth_OpenID_FileStore($store_path); - return new Auth_OpenID_FileStore($store_path); + return $r; } function &getConsumer() { @@ -68,7 +69,8 @@ function &getConsumer() { * earlier. */ $store = getStore(); - return new Auth_OpenID_Consumer($store); + $r = new Auth_OpenID_Consumer($store); + return $r; } function getScheme() { diff --git a/examples/consumer/try_auth.php b/examples/consumer/try_auth.php index 7efec76..4873140 100644 --- a/examples/consumer/try_auth.php +++ b/examples/consumer/try_auth.php @@ -37,7 +37,10 @@ function run() { $auth_request->addExtension($sreg_request); } - $policy_uris = $_GET['policies']; + $policy_uris = null; + if (isset($_GET['policies'])) { + $policy_uris = $_GET['policies']; + } $pape_request = new Auth_OpenID_PAPE_Request($policy_uris); if ($pape_request) { |