notifyall in test mode #369

Merged
tobiasd merged 3 commits from 20160906-notify into master 2016-09-09 11:53:06 +02:00
Showing only changes of commit 9f845beffd - Show all commits

View file

@ -63,7 +63,7 @@ function notifyall_post(&$a) {
}
$sql_extra = ((intval($_REQUEST['test'])) ? sprintf(" AND `email` in ( %s )", $email) : '');
$recips = q("SELECT `email` FROM `user` WHERE `verified` AND NOT `account_removed` AND NOT `account_expired` $sql_extra");
$recips = q("SELECT DISTINCT `email` FROM `user` WHERE `verified` AND NOT `account_removed` AND NOT `account_expired` $sql_extra");
if(! $recips) {
notice( t('No recipients found.') . EOL);