Show
Ignore:
Timestamp:
05/15/08 23:51:38 (19 months ago)
Author:
bchoate
Message:

Fix for async publishing so individual archive for comment is published when received (other pages are left to publish based on established rules).

Files:
1 modified

Legend:

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

    r2263 r2350  
    970970 
    971971    if ( $comment->visible ) { 
    972  
     972        $app->publisher->start_time(time); 
    973973        # Rebuild the entry synchronously so that if the user gets 
    974974        # redirected to the indiv. page it will be up-to-date. 
    975         $app->rebuild_entry( Entry => $entry->id ) 
     975        $app->rebuild_entry( Entry => $entry->id, Force => 1, PreferredArchiveOnly => 1 ) 
    976976          or return $app->handle_error( 
    977977            $app->translate( "Publish failed: [_1]", $app->errstr ) ); 
     
    991991    MT::Util::start_background_task( 
    992992        sub { 
    993             $app->rebuild_indexes( Blog => $blog ) 
    994               or return $app->errtrans( "Publish failed: [_1]", $app->errstr ); 
     993            $app->rebuild_entry( Entry => $entry->id, BuildDependencies => 1 ) 
     994              or return $app->handle_error( 
     995                $app->translate( "Publish failed: [_1]", $app->errstr ) ); 
     996 
    995997            $app->_send_comment_notification( $comment, $comment_link, $entry, 
    996998                $blog, $commenter );