summaryrefslogtreecommitdiff
path: root/classes/User.php
diff options
context:
space:
mode:
Diffstat (limited to 'classes/User.php')
-rw-r--r--classes/User.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/classes/User.php b/classes/User.php
index 643069782..ec57e52a9 100644
--- a/classes/User.php
+++ b/classes/User.php
@@ -27,11 +27,11 @@ define('WITHFRIENDS_CACHE_WINDOW', 61);
/**
* Table Definition for user
*/
-require_once 'DB/DataObject.php';
+require_once 'classes/Memcached_DataObject.php';
require_once 'Validate.php';
require_once(INSTALLDIR.'/lib/noticewrapper.php');
-class User extends DB_DataObject
+class User extends Memcached_DataObject
{
###START_AUTOCODE
/* the code below is auto generated do not remove the above tag */
@@ -65,7 +65,7 @@ class User extends DB_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return DB_DataObject::staticGet('User',$k,$v); }
+ function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('User',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
@@ -109,7 +109,12 @@ class User extends DB_DataObject
}
$qry = 'UPDATE ' . $table . ' SET ' . $toupdate .
' WHERE id = ' . $this->id;
- return $this->query($qry);
+ $orig->decache();
+ $result = $this->query($qry);
+ if ($result) {
+ $this->encache();
+ }
+ return $result;
}
function allowed_nickname($nickname) {