Reset message to non-delay type before requeuing

This commit is contained in:
Luke Fitzgerald 2010-08-10 18:34:12 -07:00
parent 8e925927c6
commit 8005bdb421

View File

@ -69,8 +69,17 @@ class IrcManager extends ImManager {
} }
} }
/**
* Request a maximum timeout for listeners before the next idle period.
*
* @return integer Maximum timeout
*/
public function timeout() { public function timeout() {
if ($this->messageWaiting) {
return 1; return 1;
} else {
return 120;
}
} }
/** /**
@ -95,7 +104,13 @@ class IrcManager extends ImManager {
$data = unserialize($wm->data); $data = unserialize($wm->data);
if (!$this->send_raw_message($data)) { if (!$this->send_raw_message($data)) {
$this->plugin->enqueue_outgoing_raw($data); $this->plugin->enqueue_outgoing_raw(
array(
'type' => 'message',
'prioritise' => $data['prioritise'],
'data' => $data['data']
)
);
} }
$wm->delete(); $wm->delete();