--- trunk/lib/WebPAC/Store.pm 2006/09/26 12:42:49 713 +++ trunk/lib/WebPAC/Store.pm 2006/09/26 12:47:52 714 @@ -71,7 +71,7 @@ my $log = $self->_get_logger(); - foreach my $p (qw/path database/) { + foreach my $p (qw/path/) { $log->logconfess("need $p") unless ($self->{$p}); } @@ -176,10 +176,9 @@ $log->logconfess("got hash, but without id") unless (defined($id)); $log->logconfess("got hash, but id [$id] isn't number") unless ($id =~ /^\d+$/); - my $database = $args->{database} || $self->{database}; - my $input = $args->{input} || ''; + my $database = $args->{database} || $self->{database} || $log->logconfess("no database?"); - $log->logconfess("can't find database name") unless ($database); + my $input = $args->{input} || ''; my $cache_file = "$cache_path/$database/$input/$id"; $cache_file =~ s#//#/#go; @@ -239,7 +238,7 @@ } my $database = $args->{database} || $self->{database}; - $log->logconfess("can't find database name") unless ($database); + $log->logconfess("can't find database name") unless (defined($database)); my $input = $args->{input} || '';