summaryrefslogtreecommitdiff
path: root/plugins/OpenID/User_openid.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2009-08-04 13:17:43 -0400
committerEvan Prodromou <evan@controlyourself.ca>2009-08-04 13:17:43 -0400
commit622c0b24c3455557bdb1bee646dcd9c955a3b3ea (patch)
treeefb03f2f7378562cf5e9f367f5c4f27ca9cfacea /plugins/OpenID/User_openid.php
parent000e21be1917b190a2aaca2e864bbf79de4796bb (diff)
move redirect-to-openid code to OpenID plugin
Diffstat (limited to 'plugins/OpenID/User_openid.php')
-rw-r--r--plugins/OpenID/User_openid.php13
1 files changed, 12 insertions, 1 deletions
diff --git a/plugins/OpenID/User_openid.php b/plugins/OpenID/User_openid.php
index f4fda1c72..338e0f6e9 100644
--- a/plugins/OpenID/User_openid.php
+++ b/plugins/OpenID/User_openid.php
@@ -4,7 +4,7 @@
*/
require_once INSTALLDIR.'/classes/Memcached_DataObject.php';
-class User_openid extends Memcached_DataObject
+class User_openid extends Memcached_DataObject
{
###START_AUTOCODE
/* the code below is auto generated do not remove the above tag */
@@ -22,4 +22,15 @@ class User_openid extends Memcached_DataObject
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
+
+ static function hasOpenID($user_id)
+ {
+ $oid = new User_openid();
+
+ $oid->user_id = $user_id;
+
+ $cnt = $oid->find();
+
+ return ($cnt > 0);
+ }
}