Florianschmidtwelzow has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/160218

Change subject: Add version check
......................................................................

Add version check

GoogleLogin v2.x requires MediaWiki 1.24, add a check for this.

Change-Id: I6e65a7e69bcf8b7cc1db9f8023fd4418071f6e07
---
M GoogleLogin.php
1 file changed, 9 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/GoogleLogin 
refs/changes/18/160218/1

diff --git a/GoogleLogin.php b/GoogleLogin.php
index ccc0e39..30c3726 100644
--- a/GoogleLogin.php
+++ b/GoogleLogin.php
@@ -26,6 +26,15 @@
                die( 'This is an extension for Mediawiki and can not run 
standalone.' );
        }
 
+       // master and v2.x requires MediaWiki 1.24
+       if ( version_compare( $wgVersion, '1.24c', '<' ) ) {
+               echo "This version of GoogleLogin requires MediaWiki 1.24, you 
have $wgVersion.<br>
+               You can <a 
href='https://www.mediawiki.org/wiki/Upgrade'>upgrade your MediaWiki 
Installation</a>
+               or <a 
href='https://www.mediawiki.org/wiki/Special:ExtensionDistributor/GoogleLogin'>download
 a 
+               version of GoogleLogin</a> which supports your MediaWiki 
version.";
+               die( -1 );
+       }
+
        $wgExtensionCredits['specialpage'][] = array(
                'path' => __FILE__,
                'name' => 'GoogleLogin',

-- 
To view, visit https://gerrit.wikimedia.org/r/160218
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6e65a7e69bcf8b7cc1db9f8023fd4418071f6e07
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/GoogleLogin
Gerrit-Branch: master
Gerrit-Owner: Florianschmidtwelzow <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to