You are here

function Messaging_Send_Method::message_queue in Messaging 7

Same name and namespace in other branches
  1. 6.4 includes/messaging_method.class.inc \Messaging_Send_Method::message_queue()
  2. 6.3 classes/messaging_method.class.inc \Messaging_Send_Method::message_queue()

Queue message for next delivery

By default it is saved to the store, though some sending methods like 'simple' may not consider queueing.

If no queue available we send the message

File

./messaging.method.inc, line 237
Drupal Messaging Framework - Send_Method class file

Class

Messaging_Send_Method
Sending method, implements all specific method functionality

Code

function message_queue($message) {
  if ($queue = messaging_store('queue')) {
    $message->queued = time();
    $queue
      ->message_queue($message);
    return TRUE;
  }
  else {
    $message->queued = 0;
    return $this
      ->message_send($message);
  }
}