diff options
author | Lilli <lilli@janrain.com> | 2010-04-28 13:39:16 -0700 |
---|---|---|
committer | Lilli <lilli@janrain.com> | 2010-04-28 13:39:16 -0700 |
commit | 8430cc6e6558dcab9ad445415eeec6aa0e7e7658 (patch) | |
tree | b27e3f9d3d151510209b0be1024955dd8a9b682f | |
parent | 1a2414c6cd0e28ddaae541b97caff07c54201414 (diff) | |
parent | 7282a89e95ebeaffe259ae0f392fcb14fa0d9423 (diff) | |
download | php-openid-8430cc6e6558dcab9ad445415eeec6aa0e7e7658.zip php-openid-8430cc6e6558dcab9ad445415eeec6aa0e7e7658.tar.gz php-openid-8430cc6e6558dcab9ad445415eeec6aa0e7e7658.tar.bz2 |
Merge branch 'master' of github.com:openid/php-openid
-rw-r--r-- | Auth/OpenID/AX.php | 2 | ||||
-rw-r--r-- | Auth/OpenID/Consumer.php | 2 | ||||
-rw-r--r-- | Auth/OpenID/SQLStore.php | 14 |
3 files changed, 3 insertions, 15 deletions
diff --git a/Auth/OpenID/AX.php b/Auth/OpenID/AX.php index 62cdee4..7370715 100644 --- a/Auth/OpenID/AX.php +++ b/Auth/OpenID/AX.php @@ -652,7 +652,7 @@ class Auth_OpenID_AX_KeyValueMessage extends Auth_OpenID_AX_Message { foreach ($aliases->iteritems() as $pair) { list($type_uri, $alias) = $pair; - if (array_key_exists('count.' . $alias, $ax_args)) { + if (array_key_exists('count.' . $alias, $ax_args) && ($ax_args['count.' . $alias] !== Auth_OpenID_AX_UNLIMITED_VALUES)) { $count_key = 'count.' . $alias; $count_s = $ax_args[$count_key]; diff --git a/Auth/OpenID/Consumer.php b/Auth/OpenID/Consumer.php index 98e408b..021c038 100644 --- a/Auth/OpenID/Consumer.php +++ b/Auth/OpenID/Consumer.php @@ -2089,7 +2089,7 @@ class Auth_OpenID_SuccessResponse extends Auth_OpenID_ConsumerResponse { foreach ($msg_args as $key => $value) { if (!$this->isSigned($ns_uri, $key)) { - return null; + unset($msg_args[$key]); } } diff --git a/Auth/OpenID/SQLStore.php b/Auth/OpenID/SQLStore.php index 5c75e70..c040597 100644 --- a/Auth/OpenID/SQLStore.php +++ b/Auth/OpenID/SQLStore.php @@ -14,16 +14,6 @@ */ /** - * Require the PEAR DB module because we'll need it for the SQL-based - * stores implemented here. We silence any errors from the inclusion - * because it might not be present, and a user of the SQL stores may - * supply an Auth_OpenID_DatabaseConnection instance that implements - * its own storage. - */ -global $__Auth_OpenID_PEAR_AVAILABLE; -$__Auth_OpenID_PEAR_AVAILABLE = @include_once 'DB.php'; - -/** * @access private */ require_once 'Auth/OpenID/Interface.php'; @@ -89,8 +79,6 @@ class Auth_OpenID_SQLStore extends Auth_OpenID_OpenIDStore { $associations_table = null, $nonces_table = null) { - global $__Auth_OpenID_PEAR_AVAILABLE; - $this->associations_table_name = "oid_associations"; $this->nonces_table_name = "oid_nonces"; @@ -113,7 +101,7 @@ class Auth_OpenID_SQLStore extends Auth_OpenID_OpenIDStore { // constant, so only try to use it if PEAR is present. Note // that Auth_Openid_Databaseconnection instances need not // implement ::setFetchMode for this reason. - if ($__Auth_OpenID_PEAR_AVAILABLE) { + if (is_subclass_of($this->connection, 'db_common')) { $this->connection->setFetchMode(DB_FETCHMODE_ASSOC); } |