From f602cb3b9d2cb1413e648d5e507fb9afcf596fe7 Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Sat, 20 Aug 2005 07:47:56 +0000 Subject: [PATCH] fix recreation conflicts --- includes/EditPage.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/includes/EditPage.php b/includes/EditPage.php index 941cef9bd8..7174d8a751 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -22,6 +22,7 @@ class EditPage { var $deletedSinceEdit = false; var $formtype; var $firsttime; + var $lastDelete; # Form values var $save = false, $preview = false, $diff = false; @@ -224,9 +225,9 @@ class EditPage { * to only perform it on saves */ if ( $this->mTitle->isDeleted() ) { - $query = $this->getLastDelete(); - if ( !is_null($query) ) { - $deletetime = $query->log_timestamp; + $this->lastDelete = $this->getLastDelete(); + if ( !is_null($this->lastDelete) ) { + $deletetime = $this->lastDelete->log_timestamp; if ( ($deletetime - $this->starttime) > 0 ) { $this->deletedSinceEdit = true; } @@ -761,7 +762,7 @@ class EditPage { // Add an confirmation checkbox and explanation. $toolbar = ''; $hidden = 'type="hidden" style="display:none;"'; - $recreate = $wgOut->parse( wfMsg( 'confirmrecreate', $query->user_name , $query->log_comment )); + $recreate = $wgOut->parse( wfMsg( 'confirmrecreate', $this->lastDelete->user_name , $this->lastDelete->log_comment )); $recreate .= "
". ""; -- 2.20.1