* @return boolean true on succesful SMTP handoff
* @access public
*/
- static function &testMail($testParams, $files, $self) {
+ static function testMail($testParams, $files, $self) {
$error = NULL;
$urlString = 'civicrm/mailing/send';
}
}
+ if (CRM_Utils_Array::value('_qf_Test_next', $testParams) &&
+ $self->get('count') <= 0) {
+ return array(
+ '_qf_default' =>
+ ts("You can not schedule or send this mailing because there are currently no recipients selected. Click 'Previous' to return to the Select Recipients step, OR click 'Save & Continue Later'."),
+ );
+ }
+
if (CRM_Utils_Array::value('_qf_Import_refresh', $_POST) ||
CRM_Utils_Array::value('_qf_Test_next', $testParams) ||
!CRM_Utils_Array::value('sendtest', $testParams)