Show
Ignore:
Timestamp:
04/13/08 04:41:46 (20 months ago)
Author:
bchoate
Message:

Applied patches from Ogawa-san to add an optimized 'exist' method for testing for existing rows. BugId:69661

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • branches/release-34/lib/MT/App/Trackback.pm

    r1866 r1873  
    560560    } 
    561561    elsif ( my $cid = $tb->category_id ) { 
    562         my $count = $app->model('entry')->count( 
     562        my $exist = $app->model('entry')->exist( 
    563563            { status => MT::Entry::RELEASE() }, 
    564564            { 
     
    569569        return $app->_response( 
    570570            Error => $app->translate( "Invalid TrackBack ID '[_1]'", $tb_id ) ) 
    571           if $count <= 0; 
     571          unless $exist; 
    572572    } 
    573573    my $rss = _generate_rss($tb);