@@ -80,8 +80,8 @@ Log::WarnDie->filter(\&filter);
8080
8181my $vwflog ; # Location of the vwf.log file, read in from the config file - default = logdir/vwf.log
8282
83- my $infocache ;
84- my $linguacache ;
83+ my $info_cache ;
84+ my $lingua_cache ;
8585my $buffercache ;
8686
8787my $script_dir = $info -> script_dir();
@@ -242,6 +242,15 @@ $logger->info('Shutting down');
242242if ($buffercache ) {
243243 $buffercache -> purge();
244244}
245+ if ($rate_limit_cache ) {
246+ $rate_limit_cache -> purge();
247+ }
248+ if ($info_cache ) {
249+ $info_cache -> purge();
250+ }
251+ if ($lingua_cache ) {
252+ $lingua_cache -> purge();
253+ }
245254CHI-> stats-> flush();
246255Log::WarnDie-> dispatcher(undef );
247256exit (0);
@@ -257,10 +266,10 @@ sub doit
257266
258267 $config ||= VWF::Config-> new({ logger => $logger , info => $info , debug => $params {' debug' } });
259268 $vwflog ||= $config -> vwflog() || File::Spec-> catfile($info -> logdir(), ' vwf.log' );
260- $infocache ||= create_memory_cache(config => $config , logger => $logger , namespace => ' CGI::Info' );
269+ $info_cache ||= create_memory_cache(config => $config , logger => $logger , namespace => ' CGI::Info' );
261270
262271 my $options = {
263- cache => $infocache ,
272+ cache => $info_cache ,
264273 logger => $logger
265274 };
266275
@@ -273,12 +282,12 @@ sub doit
273282 }
274283 $info = CGI::Info-> new($options );
275284
276- $linguacache ||= create_memory_cache(config => $config , logger => $logger , namespace => ' CGI::Lingua' );
285+ $lingua_cache ||= create_memory_cache(config => $config , logger => $logger , namespace => ' CGI::Lingua' );
277286
278287 # Language negotiation
279288 my $lingua = CGI::Lingua-> new({
280289 supported => [ ' en-gb' ],
281- cache => $linguacache ,
290+ cache => $lingua_cache ,
282291 info => $info ,
283292 logger => $logger ,
284293 debug => $params {' debug' },
0 commit comments