r101871 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r101870‎ | r101871 | r101872 >
Date:20:24, 3 November 2011
Author:jpostlethwaite
Status:ok
Tags:fundraising 
Comment:
Added comment as to why validation of the state field is ignored.
Modified paths:
  • /trunk/extensions/DonationInterface/globalcollect_gateway/modules/js/validate.js (modified) (history)

Diff [purge]

Index: trunk/extensions/DonationInterface/globalcollect_gateway/modules/js/validate.js
@@ -243,12 +243,13 @@
244244 */
245245 function validateElementState( options ) {
246246
247 - if ( !$("#state").length ) {
248 - return;
249 - }
250 -
251247 $().ready(function() {
252248
 249+ // Do not try to validate state if the field does not exist.
 250+ if ( !$("#state").length ) {
 251+ return;
 252+ }
 253+
253254 $("#state").rules("add",
254255 {
255256 required: true,

Follow-up revisions

RevisionCommit summaryAuthorDate
r102236MFT r90286, r100671, r100837, r100950, r101060, r101063, r101064, r101073, r1......khorn03:06, 7 November 2011
r102237MFT r90286, r100671, r100837, r100950, r101060, r101063, r101064, r101073, r1......khorn03:07, 7 November 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r101870Updated validation to properly handle radio buttons.jpostlethwaite20:20, 3 November 2011

Status & tagging log