wfLoadExtension() wrapper on old entrypoint
authorPlatonides <platonides@gmail.com>
Sun, 7 Jan 2018 21:42:50 +0000 (22:42 +0100)
committerPlatonides <platonides@gmail.com>
Sun, 7 Jan 2018 21:42:50 +0000 (22:42 +0100)
Paypal-wmes.php

index 495b3c471f1d55049decdad0b23f03dae24c8ef7..bbc5fbdf61d96b1688ad13dacf98fbed912c03c9 100644 (file)
@@ -1,4 +1,8 @@
 <?php
 
-$wgHooks['ParserFirstCallInit'][] = 'PaypalWMES::setup';
-$wgAutoloadClasses['PaypalWMES'] = __DIR__ . "/Paypal-wmes_body.php";
+if ( function_exists( 'wfLoadExtension' ) ) {
+       wfLoadExtension( 'Paypal-wmes' );
+} else {
+       $wgHooks['ParserFirstCallInit'][] = 'PaypalWMES::setup';
+       $wgAutoloadClasses['PaypalWMES'] = __DIR__ . "/Paypal-wmes_body.php";
+}
\ No newline at end of file