CHI requires a switch to keep track of cache size. Also, flush should be mapped to CHI's clear method. Fixes bug #11565.

This commit is contained in:
Colin Kuskie 2010-05-11 10:09:55 -07:00
parent d1559c06cf
commit 67a66647ec
2 changed files with 4 additions and 2 deletions

View file

@ -10,6 +10,7 @@
- fixed #11533: Saving entered data at registration - fixed #11533: Saving entered data at registration
- fixed #11564: Shop: Cart does not require a state field in the address - fixed #11564: Shop: Cart does not require a state field in the address
- fixed #11562: Missing perl modules in gotcha - fixed #11562: Missing perl modules in gotcha
- fixed #11565: Can't clear cache on plainblack.com
7.9.4 7.9.4
- We're shipping underscore.js now for its suite of extremely handy utility - We're shipping underscore.js now for its suite of extremely handy utility

View file

@ -59,7 +59,7 @@ Delete the entire cache namespace
sub flush { sub flush {
my ( $self ) = @_; my ( $self ) = @_;
$self->{_chi}->purge; $self->{_chi}->clear;
} }
#---------------------------------------------------------------------------- #----------------------------------------------------------------------------
@ -93,7 +93,8 @@ sub new {
my $chi; my $chi;
unless ( $chi = $session->stow->get( "CHI" ) ) { unless ( $chi = $session->stow->get( "CHI" ) ) {
my $cacheConf = $session->config->get('cache'); my $cacheConf = $session->config->get('cache');
$cacheConf->{namespace} = $namespace; $cacheConf->{namespace} = $namespace;
$cacheConf->{is_size_aware} = 1;
# Default values # Default values
my $resolveConf = sub { my $resolveConf = sub {