mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-07-03 01:31:17 +03:00
Tweak function name to be more clear
This commit is contained in:
parent
3a943e9c58
commit
27c49e2796
|
@ -51,7 +51,7 @@ function render_form_new() {
|
||||||
*/
|
*/
|
||||||
function process_form_new() {
|
function process_form_new() {
|
||||||
$submission = get_form_submission();
|
$submission = get_form_submission();
|
||||||
$has_error = validate_submission( $submission );
|
$has_error = check_invalid_submission( $submission );
|
||||||
if ( $has_error ) {
|
if ( $has_error ) {
|
||||||
return $has_error;
|
return $has_error;
|
||||||
}
|
}
|
||||||
|
@ -132,7 +132,7 @@ function render_form_manage() {
|
||||||
*/
|
*/
|
||||||
function process_form_manage() {
|
function process_form_manage() {
|
||||||
$submission = get_form_submission();
|
$submission = get_form_submission();
|
||||||
$has_error = validate_submission( $submission );
|
$has_error = check_invalid_submission( $submission );
|
||||||
if ( $has_error ) {
|
if ( $has_error ) {
|
||||||
return $has_error;
|
return $has_error;
|
||||||
}
|
}
|
||||||
|
@ -253,9 +253,9 @@ function parse_contributors( $contributors ) {
|
||||||
/**
|
/**
|
||||||
* Check the submission for valid data.
|
* Check the submission for valid data.
|
||||||
*
|
*
|
||||||
* @return false|WP_Error
|
* @return false|WP_Error Return any errors in the submission, or false if no errors.
|
||||||
*/
|
*/
|
||||||
function validate_submission( $submission ) {
|
function check_invalid_submission( $submission ) {
|
||||||
$has_required = PledgeMeta\has_required_pledge_meta( $submission );
|
$has_required = PledgeMeta\has_required_pledge_meta( $submission );
|
||||||
if ( is_wp_error( $has_required ) ) {
|
if ( is_wp_error( $has_required ) ) {
|
||||||
return $has_required;
|
return $has_required;
|
||||||
|
|
Loading…
Reference in a new issue