Yaron Koren has submitted this change and it was merged.
Change subject: Removed MW 1.19 support
......................................................................
Removed MW 1.19 support
Change-Id: If90b9bbbcf29eee3b2712a6325c0753e4c207347
---
M includes/SF_AutoeditAPI.php
1 file changed, 5 insertions(+), 10 deletions(-)
Approvals:
Yaron Koren: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/SF_AutoeditAPI.php b/includes/SF_AutoeditAPI.php
index 99e9503..145dda8 100644
--- a/includes/SF_AutoeditAPI.php
+++ b/includes/SF_AutoeditAPI.php
@@ -126,13 +126,8 @@
*/
function prepareAction() {
- // get options from the request, but keep the explicitly set
options
- global $wgVersion;
- if ( version_compare( $wgVersion, '1.20', '>=' ) ) {
- $data = $this->getRequest()->getValues();
- } else { // TODO: remove else branch when raising supported
version to MW 1.20, getValues() was buggy before
- $data = $_POST + $_GET;
- }
+ // Get options from the request, but keep the explicitly set
options.
+ $data = $this->getRequest()->getValues();
$this->mOptions = SFUtils::array_merge_recursive_distinct(
$data, $this->mOptions );
global $wgParser;
@@ -167,17 +162,17 @@
// set action to 'save' if requested
$this->mAction = self::ACTION_SAVE;
unset( $this->mOptions['wpSave'] );
- } else if ( array_key_exists( 'wpPreview', $this->mOptions ) ) {
+ } elseif ( array_key_exists( 'wpPreview', $this->mOptions ) ) {
// set action to 'preview' if requested
$this->mAction = self::ACTION_PREVIEW;
unset( $this->mOptions['wpPreview'] );
- } else if ( array_key_exists( 'wpDiff', $this->mOptions ) ) {
+ } elseif ( array_key_exists( 'wpDiff', $this->mOptions ) ) {
// set action to 'preview' if requested
$this->mAction = self::ACTION_DIFF;
unset( $this->mOptions['wpDiff'] );
- } else if ( array_key_exists( 'action', $this->mOptions ) ) {
+ } elseif ( array_key_exists( 'action', $this->mOptions ) ) {
switch ( $this->mOptions['action'] ) {
--
To view, visit https://gerrit.wikimedia.org/r/314288
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: If90b9bbbcf29eee3b2712a6325c0753e4c207347
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/SemanticForms
Gerrit-Branch: master
Gerrit-Owner: Yaron Koren <[email protected]>
Gerrit-Reviewer: Yaron Koren <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits