[MediaWiki-commits] [Gerrit] Fix PHP Notice: Undefined offset: 1 bug - change (mediawiki...ZeroBanner)
jenkins-bot has submitted this change and it was merged. Change subject: Fix PHP Notice: Undefined offset: 1 bug .. Fix PHP Notice: Undefined offset: 1 bug bug 73486 Change-Id: I25d13d1d20db8234f79e2cc7d9baa2bdde55fd73 --- M includes/PageRendering.php 1 file changed, 5 insertions(+), 4 deletions(-) Approvals: Dr0ptp4kt: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/PageRendering.php b/includes/PageRendering.php index a1e5f09..4807389 100644 --- a/includes/PageRendering.php +++ b/includes/PageRendering.php @@ -584,16 +584,17 @@ if ( $this-config === false || ( $this-config $this-config-contextMode() !== $mode ) ) { wfProfileIn( __METHOD__ ); + $ipset = ''; $xcs = $this-getConfigId(); // Unified is treated as if there is no config - we don't know the actual ID if ( $xcs !== null !$this-isUnifiedZero() ) { - @list( $id, $ipset ) = explode( '|', $xcs, 2 ); - if ( $ipset === null ) { - $ipset = ''; + $xcsParts = explode( '|', $xcs, 2 ); + $id = $xcsParts[0]; + if ( count( $xcsParts ) 1 ) { + $ipset = $xcsParts[1]; } } else { $id = null; - $ipset = ''; } if ( $id !== null $this-config === false ) { -- To view, visit https://gerrit.wikimedia.org/r/173744 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I25d13d1d20db8234f79e2cc7d9baa2bdde55fd73 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/ZeroBanner Gerrit-Branch: master Gerrit-Owner: Yurik yu...@wikimedia.org Gerrit-Reviewer: Dr0ptp4kt ab...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix PHP Notice: Undefined offset: 1 bug - change (mediawiki...ZeroBanner)
Yurik has uploaded a new change for review. https://gerrit.wikimedia.org/r/173744 Change subject: Fix PHP Notice: Undefined offset: 1 bug .. Fix PHP Notice: Undefined offset: 1 bug bug 73486 Change-Id: I25d13d1d20db8234f79e2cc7d9baa2bdde55fd73 --- M includes/PageRendering.php 1 file changed, 5 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ZeroBanner refs/changes/44/173744/1 diff --git a/includes/PageRendering.php b/includes/PageRendering.php index 3cb7456..d2e8ed3 100644 --- a/includes/PageRendering.php +++ b/includes/PageRendering.php @@ -584,16 +584,17 @@ if ( $this-config === false || ( $this-config $this-config-contextMode() !== $mode ) ) { wfProfileIn( __METHOD__ ); + $ipset = ''; $xcs = $this-getConfigId(); // Unified is treated as if there is no config - we don't know the actual ID if ( $xcs !== null !$this-isUnifiedZero() ) { - @list( $id, $ipset ) = explode( '|', $xcs, 2 ); - if ( $ipset === null ) { - $ipset = ''; + $xcsParts = explode( '|', $xcs, 2 ); + $id = $xcsParts[0]; + if ( count( $xcsParts ) 1 ) { + $ipset = $xcsParts[1]; } } else { $id = null; - $ipset = ''; } if ( $id !== null $this-config === false ) { -- To view, visit https://gerrit.wikimedia.org/r/173744 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I25d13d1d20db8234f79e2cc7d9baa2bdde55fd73 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/ZeroBanner Gerrit-Branch: master Gerrit-Owner: Yurik yu...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits