summaryrefslogtreecommitdiff
path: root/plugins/OpenID
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-03-05 15:00:27 -0800
committerBrion Vibber <brion@pobox.com>2010-03-05 15:00:27 -0800
commit5355c3b7b579f803bb18913db3b4d9cf380f17ac (patch)
tree67a05d6ca65fa6fb919f9fb8817ed5f4d3b8fe42 /plugins/OpenID
parent54de8ad9f20a51cdaf78404c45e91a1f652670f1 (diff)
OpenID fix:
- avoid notice on insert (missing sequenceKeys()) - avoid cache corruption on delete (user_id was missing from keys list, cache not cleared for user_id lookups)
Diffstat (limited to 'plugins/OpenID')
-rw-r--r--plugins/OpenID/User_openid.php14
1 files changed, 13 insertions, 1 deletions
diff --git a/plugins/OpenID/User_openid.php b/plugins/OpenID/User_openid.php
index 801b49ecc..5ef05b4c7 100644
--- a/plugins/OpenID/User_openid.php
+++ b/plugins/OpenID/User_openid.php
@@ -39,9 +39,21 @@ class User_openid extends Memcached_DataObject
);
}
+ /**
+ * List primary and unique keys in this table.
+ * Unique keys used for lookup *MUST* be listed to ensure proper caching.
+ */
function keys()
{
- return array('canonical' => 'K', 'display' => 'U');
+ return array('canonical' => 'K', 'display' => 'U', 'user_id' => 'U');
+ }
+
+ /**
+ * No sequence keys in this table.
+ */
+ function sequenceKey()
+ {
+ return array(false, false, false);
}
Static function hasOpenID($user_id)