in function _comment_notify_mailalert(), $language was changed but did not get reverted back to $initial_language. This causes the $language variable isn't consistent and it's affecting other modules that relies on $language.

Attached patch:

Index: comment_notify.module
===================================================================
--- comment_notify.module (revision 35670)
+++ comment_notify.module (working copy)
@@ -538,11 +538,11 @@
'fragment' => 'comment-' . $alert->cid,
))
);
-
- // Revert to previous (site default) locale.
- $language = $initial_language;
}
}
+ // Revert to previous (site default) locale.
+ $language = $initial_language;
+
// Record that a notification was sent for this comment so that
// notifications aren't sent again if the comment is later edited.
comment_notify_mark_comment_as_notified($comment);

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

kscheirer’s picture

Version: 7.x-1.2 » 7.x-1.x-dev
Status: Active » Needs review

Seems like a good fix, issue is still present in 7.x-1.x-dev. It's not nice to leave the language global in a bad state.

Status: Needs review » Needs work

The last submitted patch, comment_notify.module.patch, failed testing.

kscheirer’s picture

Status: Needs work » Needs review
FileSize
670 bytes

Rerolled.