aboutsummaryrefslogtreecommitdiff
path: root/mod/messages/views/default
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-02-19 21:43:44 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-02-19 21:43:44 +0000
commit257e2fa95b7959605f7349a561c5ade8620e765c (patch)
tree9dce6e4d1de136f257a7d4e2467c10d29e8a647e /mod/messages/views/default
parent5b6d7def3fd7d4a5c5845eb9f2e2e37af3da503e (diff)
downloadelgg-257e2fa95b7959605f7349a561c5ade8620e765c.tar.gz
elgg-257e2fa95b7959605f7349a561c5ade8620e765c.tar.bz2
Can send messages to non-friends.
git-svn-id: http://code.elgg.org/elgg/trunk@8351 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/messages/views/default')
-rw-r--r--mod/messages/views/default/forms/messages/send.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/mod/messages/views/default/forms/messages/send.php b/mod/messages/views/default/forms/messages/send.php
index db857b6f4..c0a095993 100644
--- a/mod/messages/views/default/forms/messages/send.php
+++ b/mod/messages/views/default/forms/messages/send.php
@@ -15,6 +15,13 @@ foreach ($vars['friends'] as $friend) {
$recipients_options[$friend->guid] = $friend->name;
}
+if (!array_key_exists($recipient_guid, $recipients_options)) {
+ $recipient = get_entity($recipient_guid);
+ if (elgg_instanceof($recipient, 'user')) {
+ $recipients_options[$recipient_guid] = $recipient->name;
+ }
+}
+
$recipient_drop_down = elgg_view('input/dropdown', array(
'name' => 'recipient_guid',
'value' => $recipient_guid,