Commit 006865ba authored by Stephen Shkardoon's avatar Stephen Shkardoon

Merge pull request #72 from sasky/master

FIX Mailing list tab doesn't work if no Mailing lists or Recipients
parents 2a3229f1 ab2de6fb
......@@ -114,6 +114,9 @@ class MailingList extends DataObject {
* Returns all recipients who aren't blacklisted, and are verified.
*/
public function ActiveRecipients() {
if($this->Recipients() instanceof UnsavedRelationList ) {
return new ArrayList();
}
return $this->Recipients()->exclude('Blacklisted', 1)->exclude('Verified', 0);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment