From 83b144cb42beaa3f5ba82e7d18f73c22dc1f27c8 Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Fri, 9 Apr 2004 15:24:22 +0000 Subject: [PATCH] Some browsers allow submission of the form without setting wpSave. Restoring the previous behaviour (treat as save) --- includes/EditPage.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/includes/EditPage.php b/includes/EditPage.php index 6fe2392493..4293b84821 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -52,7 +52,6 @@ class EditPage { } return; } - if( !$wgRequest->wasPosted() ) $this->save = false; if ( $this->save ) { $this->editForm( "save" ); } else if ( $this->preview ) { @@ -73,8 +72,8 @@ class EditPage { $this->edittime = $request->getVal( 'wpEdittime' ); if( !preg_match( '/^\d{14}$/', $this->edittime ) ) $this->edittime = ""; - $this->save = $request->getCheck( 'wpSave' ); $this->preview = $request->getCheck( 'wpPreview' ); + $this->save = $request->wasPosted() && !$this->preview; $this->minoredit = $request->getCheck( 'wpMinoredit' ); $this->watchthis = $request->getCheck( 'wpWatchthis' ); -- 2.20.1