You are here

protected function Notifications_Queue::process_send in Notifications 6.4

Send array of messages through messaging module

Parameters

$destination: Messaging destination to send to

$messages: Array of messages prepared for sending

$test: Optional just test composition and formating but do not send

File

includes/notifications_queue.class.inc, line 623

Class

Notifications_Queue
Queue management and processing

Code

protected function process_send($method, $destination, $messages) {
  notifications_log('Sending out notifications', array(
    'method' => $method,
    'address' => $destination->address,
    'messages' => count($messages),
  ));
  $test = $this
    ->process_option('test');
  foreach ($messages as $message) {
    $this
      ->message_send($method, $destination, $message, $test);
  }
  return $messages;
}