01tonythomas has uploaded a new change for review.
https://gerrit.wikimedia.org/r/172788
Change subject: Made the VERP address generation optional
......................................................................
Made the VERP address generation optional
Now, the admin can chose whether or not to start producing VERP address
on send emails
Change-Id: I0e62994bcfe709c8969379f3bea159c9b52d0dfb
---
M BounceHandler.php
M BounceHandlerHooks.php
2 files changed, 4 insertions(+), 1 deletion(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BounceHandler
refs/changes/88/172788/1
diff --git a/BounceHandler.php b/BounceHandler.php
index 308cdf3..0d2fb23 100644
--- a/BounceHandler.php
+++ b/BounceHandler.php
@@ -49,6 +49,7 @@
/**
* VERP Configurations
+ * $wgGenerateVERP - Toggle VERP generation
* wgVERPprefix - The prefix of the VERP address.
* wgVERPdomainPart - The domain part of the VERP email address, defaults to
$wgServerName
* wgVERPalgorithm - Algorithm to hash the return path address.Possible
algorithms are
@@ -56,6 +57,7 @@
* wgVERPsecret - The secret key to hash the return path address
* wgBounceHandlerUnconfirmUsers - Toggle the user un-subscribe action
*/
+$wgGenerateVERP = false;
$wgVERPprefix = 'wiki';
$wgVERPdomainPart = null; //set this only if you want the domain part of your
email different from your wgServerName
$wgVERPalgorithm = 'md5';
diff --git a/BounceHandlerHooks.php b/BounceHandlerHooks.php
index 8139481..f186afe 100644
--- a/BounceHandlerHooks.php
+++ b/BounceHandlerHooks.php
@@ -14,7 +14,8 @@
* @throws InvalidArgumentException
*/
public static function onVERPAddressGenerate( array $recip,
&$returnPath ) {
- if ( count( $recip ) === 1 ) {
+ global $wgGenerateVERP;
+ if ( $wgGenerateVERP == true && count( $recip ) === 1 ) {
self::generateVerp( $recip[0], $returnPath );
}
--
To view, visit https://gerrit.wikimedia.org/r/172788
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I0e62994bcfe709c8969379f3bea159c9b52d0dfb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/BounceHandler
Gerrit-Branch: master
Gerrit-Owner: 01tonythomas <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits