Plugin Directory

Changeset 1504489


Ignore:
Timestamp:
09/28/2016 01:35:29 PM (10 years ago)
Author:
thebluecube
Message:

Fixing a bug in the maybeMarkTheFormAsValid method.

Location:
bluecube-mighty-gravity-forms
Files:
5 added
3 edited

Legend:

Unmodified
Added
Removed
  • bluecube-mighty-gravity-forms/trunk/bluecube-mighty-gravityforms.php

    r1504333 r1504489  
    66 * Description: This plugin adds some advanced features to Gravity Forms e.g. custom validation rules etc.
    77 * Author: Blue Cube Communications Ltd
    8  * Version: 1.1
     8 * Version: 1.1.1
    99 * Author URI: https://thebluecube.com
    1010 * License: GPLv2 or later
  • bluecube-mighty-gravity-forms/trunk/class/Mighty_Gravity_Forms.php

    r1504333 r1504489  
    575575     */
    576576    protected function maybeMarkTheFormAsValid($field)
    577     {
    578         $invalid_inputs = array_filter($this->validation_result['form']['fields'], function ($input){
    579             return $input->validation_message != '';
    580         });
    581 
    582         if (count($invalid_inputs) == 1 && $invalid_inputs[0]->id == $field->id)
    583             $this->validation_result['is_valid'] = true;
    584     }
     577     {
     578         $invalid_inputs = array_filter($this->validation_result['form']['fields'], function ($input){
     579             return $input->validation_message != '';
     580         });
     581
     582         if ( count($invalid_inputs) == 1 ) {
     583             $invalid_input = array_shift($invalid_inputs);
     584             if ( $invalid_input->id == $field->id )
     585                 $this->validation_result['is_valid'] = true;
     586         }
     587     }
    585588
    586589    /**
  • bluecube-mighty-gravity-forms/trunk/readme.txt

    r1504333 r1504489  
    55Requires at least: 4.6
    66Tested up to: 4.6.1
    7 Stable tag: 1.1
     7Stable tag: 1.1.1
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3535== Changelog ==
    3636
     37= 1.1.1 =
     38* Fixing a bug in the maybeMarkTheFormAsValid method
     39
    3740= 1.1 =
    3841* Adding advanced conditional logic shortcode to be used in email notifications
Note: See TracChangeset for help on using the changeset viewer.