madeon (madeon) wrote in changelog,
madeon
madeon
changelog

[livejournal] r22850: LJSUP-13594: MemCacheProxy do not sent t...

Committer: sbelyaev
LJSUP-13594: MemCacheProxy do not sent to MemCache all information
U   trunk/cgi-bin/LJ/MemCacheProxy.pm
Modified: trunk/cgi-bin/LJ/MemCacheProxy.pm
===================================================================
--- trunk/cgi-bin/LJ/MemCacheProxy.pm	2012-09-10 12:54:28 UTC (rev 22849)
+++ trunk/cgi-bin/LJ/MemCacheProxy.pm	2012-09-10 13:36:57 UTC (rev 22850)
@@ -12,16 +12,16 @@
 }
 
 sub get {
-    my ($key) = @_;
+    my ($key_origin) = @_;
 
-    $key = $key->[1]
-        if ref $key eq 'ARRAY';
+    my $key = $key_origin->[1]
+        if ref $key_origin eq 'ARRAY';
     
     if (exists $singletons{$key}) {
         return $singletons{$key};
     }
 
-    my $value = LJ::MemCache::get($key);
+    my $value = LJ::MemCache::get($key_origin);
     $singletons{$key} = $value;
     return $value;
 }
@@ -54,33 +54,33 @@
 }
 
 sub delete {
-    my ($key) = @_;
+    my ($key_origin) = @_;
 
-    $key = $key->[1]
-        if ref $key eq 'ARRAY';
+    my $key = $key_origin->[1]
+        if ref $key_origin eq 'ARRAY';
 
     delete $singletons{$key};
-    LJ::MemCache::delete($key);
+    LJ::MemCache::delete($key_origin);
 }
 
 sub set {
-    my ($key, $value, $expire) = @_;
+    my ($key_origin, $value, $expire) = @_;
 
-    $key = $key->[1]
-        if ref $key eq 'ARRAY';
+    my $key = $key_origin->[1]
+        if ref $key_origin eq 'ARRAY';
 
     $singletons{$key} = $value;
-    return LJ::MemCache::set($key, $value, $expire);
+    return LJ::MemCache::set($key_origin, $value, $expire);
 }
 
 sub replace {
-    my ( $key, $value, $expire ) = @_;
+    my ( $key_origin, $value, $expire ) = @_;
 
-    $key = $key->[1]
-        if ref $key eq 'ARRAY';
+    my $key = $key_origin->[1]
+        if ref $key_origin eq 'ARRAY';
 
     $singletons{$key} = $value;
-    return LJ::MemCache::replace($key, $value, $expire);
+    return LJ::MemCache::replace($key_origin, $value, $expire);
 }
 
 1;

Tags: livejournal, madeon, pm, sbelyaev
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments