Skip to content

Commit

Permalink
Update includes/service-providers/mailchimp/class-newspack-newsletter…
Browse files Browse the repository at this point in the history
…s-mailchimp.php

Co-authored-by: Adam Cassis <adam@adamcassis.com>
  • Loading branch information
dkoo and adekbadek authored Nov 1, 2024
1 parent 41db9b6 commit f34334f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1426,7 +1426,7 @@ public function validate( $result, $preferred_error = null ) {
throw new Exception( esc_html__( 'A Mailchimp error has occurred.', 'newspack-newsletters' ) );
}
}
if ( ! empty( $result['status'] ) && 400 <= (int) $result['status'] ) {
if ( ! empty( $result['status'] ) && (int) $result['status'] >= 400 ) {
if ( $preferred_error && ! Newspack_Newsletters::debug_mode() ) {
if ( ! empty( $result['detail'] ) ) {
$preferred_error .= ' ' . $result['detail'];
Expand Down

0 comments on commit f34334f

Please sign in to comment.