spivurno
8/31/2017 - 11:03 PM

Gravity Wiz // Gravity Forms Coupons // Allow Zero Amount Coupons

Gravity Wiz // Gravity Forms Coupons // Allow Zero Amount Coupons

<?php
/**
 * Gravity Wiz // Gravity Forms Coupons // Allow Zero Amount Coupons
 * http://gravitywiz.com/
 */
add_filter( 'gform_gravityformscoupons_feed_settings_fields', function( $settings ) {

	foreach( $settings as &$group ) {
		foreach( $group['fields'] as &$field ) {
			if( $field['name'] == 'couponAmountType' ) {
				$field['validation_callback'] = null;
			}
		}
	}

	return $settings;
} );