git.gnu.io has moved to IP address 209.51.188.249 -- please double check where you are logging in.

Commit f7769c17 authored by mmn's avatar mmn

Merge branch 'subscribers_as_addressees' into 'nightly'

Add subscribers as addressees to toselector

Populate the dropdown recipient menu first with groups, then with followed users. There is no alphabetical sorting (perhaps to be added later?). See this discussion https://gnusocial.no/conversation/190705#notice-190705. Thanks to @chimo.

Hope it is good now.

See merge request !14
parents 3a910d8c 76c9971c
......@@ -102,7 +102,16 @@ class ToSelector extends Widget
$choices[$value] = $groups->getBestName();
}
// XXX: add users...?
// Add subscribed users to dropdown menu
$users = $this->user->getSubscribed();
while ($users->fetch()) {
$value = 'profile:'.$users->id;
if ($this->user->streamNicknames()) {
$choices[$value] = $users->getNickname();
} else {
$choices[$value] = $users->getBestName();
}
}
if ($this->to instanceof Profile) {
$value = 'profile:'.$this->to->id;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment