10, 'body' => array( 'secret' => (string) get_option( 'mapp_turnstile_secret' ), 'response' => $token, 'remoteip' => $ip, ), ) ); if ( is_wp_error( $response ) ) { // Fail open on Cloudflare outages; rate limits still apply. return true; } $body = json_decode( wp_remote_retrieve_body( $response ), true ); if ( ! empty( $body['success'] ) ) { return true; } return new \WP_Error( 'mapp_bot_check', __( 'Please complete the security check and try again.', '1003-mortgage-application' ), array( 'status' => 400 ) ); } }