summaryrefslogtreecommitdiff
path: root/classes/Memcached_DataObject.php
diff options
context:
space:
mode:
Diffstat (limited to 'classes/Memcached_DataObject.php')
-rw-r--r--classes/Memcached_DataObject.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/classes/Memcached_DataObject.php b/classes/Memcached_DataObject.php
index ab56d2474..ff1ca0bdf 100644
--- a/classes/Memcached_DataObject.php
+++ b/classes/Memcached_DataObject.php
@@ -24,6 +24,11 @@ require_once INSTALLDIR.'/classes/Memcached_DataObject.php';
class Memcached_DataObject extends DB_DataObject
{
function &staticGet($cls, $k, $v=NULL) {
+ if (is_null($v)) {
+ $v = $k;
+ $keys = $cls->keys();
+ $k = $keys[0];
+ }
$i = Memcached_DataObject::getcached($cls, $k, $v);
if (!is_null($i)) {
return $i;