From: Adam Roses Wight Date: Thu, 5 Jun 2014 00:13:31 +0000 (-0700) Subject: Soften test for incomplete edit POST X-Git-Tag: 1.31.0-rc.0~15465^2 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/modifier.php?a=commitdiff_plain;h=05a19c5ba7145bed7c2a323e5f6c9e9babea53a0;p=lhc%2Fweb%2Fwiklou.git Soften test for incomplete edit POST Do not reject POSTs from forms that were rendered before wpUltimateParam was added. There is also an open question about whether we should respect kludgey scripts which have hardcoded form params. See Umherirrender's comment on change I78f1bbcc9bb092568fbfbec19c08d697c9ae75f8 Change-Id: I28bd6d45442bc3ba352f0de7a50709adb98b1c50 --- diff --git a/includes/EditPage.php b/includes/EditPage.php index 8f85c1816c..9108783523 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -799,7 +799,11 @@ class EditPage { } else { // If we receive the last parameter of the request, we can fairly // claim the POST request has not been truncated. - $this->incompleteForm = !$request->getVal( 'wpUltimateParam' ); + + // TODO: softened the check for cutover. Once we determine + // that it is safe, we should complete the transition by + // removing the "edittime" clause. + $this->incompleteForm = ( !$request->getVal( 'wpUltimateParam' ) && is_null( $this->edittime ) ); } if ( $this->incompleteForm ) { # If the form is incomplete, force to preview.