Last active
July 10, 2016 23:03
-
-
Save spivurno/3d163fe8f14be0f57753 to your computer and use it in GitHub Desktop.
Gravity Perks // GP Limit Choies // Disable Limits for Admins
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Gravity Perks // GP Limit Choies // Disable Limits for Admins | |
* http://gravitywiz.com/ | |
*/ | |
add_action( 'init', function() { | |
if( is_callable( 'gp_limit_choices' ) && current_user_can( 'administrator' ) ) { | |
add_filter( 'gplc_remove_choices', '__return_false' ); | |
add_filter( 'gplc_disable_choices', '__return_false' ); | |
remove_filter( 'gform_validation', array( gp_limit_choices(), 'validate' ) ); | |
} | |
}, 11 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment