Doesn't work when a user is assigned to multiple roles
mellenburg - May 12, 2009 - 18:12
| Project: | Mass Contact |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Jump to:
Description
I have users that are assigned to multiple roles. Whenever I try to send and email to those roles, only the users belonging to that role and no others receive the email.

#1
Actually, it does appear to work, but the message displayed is incorrect. I have a group called site administrators with one member. When I send to that group, the message says no recipients are found, but the email is received.
#2
As I tested it, I did not see any of this behavior, so maybe I'm not understanding what you are saying.
#3
i think the module does not display it, when you send it to yourself (as user 1) if you were the only one belonging to that role you mentioned
#4
Okay, I played around with this last night and this morning, and I think I know what it is you are experiencing.
The behavior of Mass Contact is such that it removes the sender from the list of recipients, so if the sender is the only person in the category, it would not send the message, because there would ultimately be no recipients. However, there was a logic flow bug where Mass Contact would continue to try to send the message anyway. I believe I have fixed that, so it doesn't attempt to send anyway, and you won't get the confusing error message. I also made some changes to the error reporting so that it (hopefully) is clearer as to what is happening. I also pulled the copy to self functionality out of that logic, so that a person could test sending w/o getting any real errors.
What you should see now is one message stating that there are no recipients for the category and that the message was not sent, and another message stating that a carbon copy was sent to you (if you selected the "Send yourself a copy" checkbox).
Hopefully that will fix these problems, but if not, feel free to reopen this issue with more information.
Here is the commit, if you want to wade through the gory details: http://drupal.org/cvs?commit=253314
#5
Automatically closed -- issue fixed for 2 weeks with no activity.