Echo: Fix bugs related to replication lag

Change-Id: I9f49796c3e85cae5f9bd996ed0cb30720b244056
This commit is contained in:
Andrew Garrett 2012-08-01 16:25:32 -07:00
parent 5a37ea4684
commit 80a8b99719

View file

@ -15,7 +15,7 @@ abstract class EchoDiscussionParser {
static function generateEventsForRevision( $revision ) {
$interpretation = self::getChangeInterpretationForRevision( $revision );
$createdEvents = false;
$title = $revision->getTitle();
$title = Title::newFromID( $revision->getPage() );
$userID = $revision->getUser();
$userName = $revision->getUserText();
@ -122,7 +122,7 @@ abstract class EchoDiscussionParser {
$userID = $revision->getUser();
$userName = $revision->getUserText();
$user = $userID != 0 ? User::newFromId( $userID ) : User::newFromName( $userName, false );
$prevRevision = $revision->getPrevious();
$prevRevision = Revision::newFromId( $revision->getParentId() );
$changes = self::getMachineReadableDiff( $prevRevision->getText(), $revision->getText() );
$output = self::interpretDiff( $changes, $user->getName() );