/[webpac2]/trunk/lib/WebPAC/Search/Estraier.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/lib/WebPAC/Search/Estraier.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 86 by dpavlin, Tue Nov 22 08:37:40 2005 UTC revision 87 by dpavlin, Tue Nov 22 08:37:45 2005 UTC
# Line 115  sub search { Line 115  sub search {
115    
116          my $log = $self->_get_logger;          my $log = $self->_get_logger;
117    
118          $log->logconfess('need db in object') unless ($self->{'db'});          $self->confess('need db in object') unless ($self->{'db'});
119          $log->logconfess('need attr') unless ($args->{'attr'});          $self->confess('need attr') unless ($args->{'attr'});
120    
121          $log->logconfess("need attr as array not " . ref($args->{'attr'}) ) unless (ref($args->{'attr'}) eq 'ARRAY');          $self->confess("need attr as array not " . ref($args->{'attr'}) ) unless (ref($args->{'attr'}) eq 'ARRAY');
122    
123          my $q = $args->{'query'};          my $q = $args->{'query'};
124    
# Line 163  sub search { Line 163  sub search {
163    
164          $log->debug("results " . Dumper( \@results ));          $log->debug("results " . Dumper( \@results ));
165    
166          $log->logconfess("expected to return array") unless (wantarray);          $self->confess("expected to return array") unless (wantarray);
167    
168          return @results;          return @results;
169  }  }
# Line 179  C<die>. Line 179  C<die>.
179  sub confess {  sub confess {
180          my $self = shift;          my $self = shift;
181          if (my $log = $self->{'log'}) {          if (my $log = $self->{'log'}) {
182                  if ($log->can('confess')) {                  if ($log->can('logconfess')) {
183                          $log->confess(@_);                          $log->logconfess(@_);
184                  } elsif ($log->can('fatal')) {                  } elsif ($log->can('fatal')) {
185                          $log->fatal(@_);                          $log->fatal(@_);
186                            die @_;
187                  } elsif ($log->can('error')) {                  } elsif ($log->can('error')) {
188                          $log->error(@_);                          $log->error(@_);
189                  } else {                  } else {

Legend:
Removed from v.86  
changed lines
  Added in v.87

  ViewVC Help
Powered by ViewVC 1.1.26