jenkins-bot has submitted this change and it was merged.

Change subject: Throw errors if required fields missing
......................................................................


Throw errors if required fields missing

To make it easier to find problems for developers.

Change-Id: I2671b50ff4731d9b8040c563b7b808ea15b964f7
---
M BetaFeaturesHooks.php
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  BryanDavis: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/BetaFeaturesHooks.php b/BetaFeaturesHooks.php
index 8402b2d..e7b59c9 100644
--- a/BetaFeaturesHooks.php
+++ b/BetaFeaturesHooks.php
@@ -57,7 +57,7 @@
                                        // we got from the 
GetBetaFeaturePreferences hook.
                                        // Don't add this feature to the form.
                                        $complete = false;
-                                       break;
+                                       throw new Exception( "The field 
{$field} was missing from the beta feature {$key}." );
                                }
                        }
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2671b50ff4731d9b8040c563b7b808ea15b964f7
Gerrit-PatchSet: 5
Gerrit-Project: mediawiki/extensions/BetaFeatures
Gerrit-Branch: master
Gerrit-Owner: MarkTraceur <[email protected]>
Gerrit-Reviewer: BryanDavis <[email protected]>
Gerrit-Reviewer: jenkins-bot

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

Reply via email to