Your problem is with the conditional, not with the used action (I think).
This line is probably not verifying in any situation:
if( ( $_POST['post_status'] == 'publish' ) && ( $goalsupport === $totalsupport ) ) {
I can not now what $goalsupport and $goalsupport are, both variables are undefined in your code, so I’m going to remove them. Change that line with this one:
if( get_post_status( $post_id ) == 'publish' ) {
So, the code should be:
function emailNotificationSuccess($post_id) {
if( get_post_status( $post_id ) == 'publish' ) {
$post = get_post($post_id);
$author = get_userdata($post->post_author);
$totalsupport = countSupportForAll($post->ID);
$goalsupport = get_post_meta( $post->ID, 'sj_campaign_goal', true );
$supporter_email = get_post_meta( $post_id, 'sj_campaign_email', true );
$message = "Hi ".$author->display_name.",
Congrats! You have reached your goal!
Your , ".$post->post_title." is a success!
".get_permalink( $post_id )."
";
wp_mail($supporter_email, "You just reached your goal!", $message);
}
}
add_action('post_updated', 'emailNotificationSuccess');