|
@@ -833,8 +833,12 @@ function sendpm($recipients, $subject, $message, $store_outbox = false, $from =
|
|
|
if ($smcFunc['strlen']($htmlsubject) > 100)
|
|
|
$htmlsubject = $smcFunc['substr']($htmlsubject, 0, 100);
|
|
|
|
|
|
+ // Make sure is an array
|
|
|
+ if (!is_array($recipients))
|
|
|
+ $recipients = array($recipients);
|
|
|
+
|
|
|
// Integrated PMs
|
|
|
- call_integration_hook('integrate_personal_message', array(&$recipients, &$from['username'], &$subject, &$message));
|
|
|
+ call_integration_hook('integrate_personal_message', array(&$recipients, &$from, &$subject, &$message));
|
|
|
|
|
|
// Get a list of usernames and convert them to IDs.
|
|
|
$usernames = array();
|