File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed
Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ use Template::Plugin::EnvHash;
2727use Template::Plugin::Math;
2828use Template::Plugin::JSON;
2929use HTML::SocialMedia;
30- use VWF::Utils qw( create_memory_cache create_disc_cache ) ;
30+ use VWF::Utils qw( create_memory_cache) ;
3131use Error;
3232use Fatal qw( :void open) ;
3333use File::pfopen;
Original file line number Diff line number Diff line change @@ -204,6 +204,12 @@ sub _validate_cache_config($config, $cache_type) {
204204 croak(' Port must be between 1 and 65535' )
205205 unless $port >= 1 && $port <= 65535;
206206 }
207+
208+ # Validate memory parameters
209+ if (exists ($cache_config -> {' datastore' }) && exists ($cache_config -> {' global' }) && (my $driver = $cache_config -> {' driver' })) {
210+ # CHI catches this as well, but putting it here helps to track the error
211+ croak(' Memory cache cannot have both global and datastore' );
212+ }
207213}
208214
209215sub _get_default_driver ($cache_type , $logger ) {
You can’t perform that action at this time.
0 commit comments