Changeset 28

Show
Ignore:
Timestamp:
02/12/07 20:44:19 (2 years ago)
Author:
simon
Message:

So near and yet so far.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Tagtools.pm

    r26 r28  
    1919        my ($self, $codeblock,$arg) = @_; 
    2020        my $key = 0+$codeblock; if ($arg) { $key .=":".encode_base64(freeze(\$arg));  } 
    21         my $c = $cache->get(0+$codeblock); return @$c if $c; 
     21        my $c = $cache->get($key); return @$c if $c; 
    2222        my @stuff = $codeblock->($arg); 
    23         $cache->set(0+$codeblock, [ @stuff ]); 
     23        $cache->set($key, [ @stuff ]); 
    2424        return @stuff; 
    2525    };