Changeset 2318

Show
Ignore:
Timestamp:
05/14/08 00:43:20 (21 months ago)
Author:
fumiakiy
Message:

Improved the error message returned when the request was throttled. BugId:50084, BugId:66624

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • branches/release-38/lib/MT/App/Search.pm

    r2267 r2318  
    828828    my $msg = $messages && @$messages 
    829829      ? join '; ', @$messages 
    830       : $app->translate('Throttled'); 
     830      : $app->translate('The search you conducted has timed out.  Please simplify your query and try again.'); 
    831831    return $app->error($msg); 
    832832} 
     
    865865    unless ( $^O eq 'Win32' ) { 
    866866        # Use SIGALRM to stop processing in 5 seconds for each request 
    867         $SIG{ALRM} = sub { $app->errtrans('Throttled'); die; }; 
     867        $SIG{ALRM} = sub { 
     868            my $msg = $app->translate('The search you conducted has timed out.  Please simplify your query and try again.'); 
     869            $app->error($msg); 
     870            die $msg; 
     871        }; 
    868872        $app->{__have_throttle} = 1; 
    869873        alarm($app->config->SearchThrottleSeconds);