]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Add table() and keys() overrides to User_username
authorCraig Andrews <candrews@integralblue.com>
Thu, 10 Dec 2009 19:40:26 +0000 (14:40 -0500)
committerCraig Andrews <candrews@integralblue.com>
Thu, 10 Dec 2009 19:40:26 +0000 (14:40 -0500)
plugins/Authentication/User_username.php

index f30f60d839a6462bd706d49c1548188e827ba9ae..853fd5cb86a109f28a69569c293d78d0837fcc2a 100644 (file)
@@ -43,4 +43,19 @@ class User_username extends Memcached_DataObject
             return false;
         }
     }
+
+    function table() {
+        return array(
+            'user_id'     => DB_DATAOBJECT_INT,
+            'username'   => DB_DATAOBJECT_STR,
+            'provider_name'   => DB_DATAOBJECT_STR ,
+            'created'   => DB_DATAOBJECT_STR + DB_DATAOBJECT_DATE + DB_DATAOBJECT_TIME
+        );
+    }
+
+    // now define the keys.
+    function keys() {
+        return array('provider_name', 'username');
+    }
+
 }