From: erickson Date: Tue, 12 Apr 2005 14:48:08 +0000 (+0000) Subject: checking for only one server X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=9670c0b9e890d2932b5c40f635c95c82ef8535f9;p=opensrf%2Fbjwebb.git checking for only one server git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@274 9efc2488-bf62-4759-914b-345cdb29e865 --- diff --git a/src/perlmods/OpenSRF/Utils/Cache.pm b/src/perlmods/OpenSRF/Utils/Cache.pm index e972ae7..279adde 100644 --- a/src/perlmods/OpenSRF/Utils/Cache.pm +++ b/src/perlmods/OpenSRF/Utils/Cache.pm @@ -72,6 +72,10 @@ sub new { my $servers = $conf->config_value( cache => $cache_type => servers => 'server' ); my $expire_time = $conf->config_value( cache => $cache_type => 'max_cache_time' ); + if(!ref($servers)){ + $servers = [ $servers ]; + } + my $self = {}; $self->{persist} = $persist || 0; $self->{memcache} = Cache::Memcached->new( { servers => $servers } );