Rename get_realm_persons() to get_realm_users().

The function's name was misleading, since it includes
any bots in your realm.
This commit is contained in:
Steve Howell
2020-03-21 18:53:16 +00:00
committed by Tim Abbott
parent 7ac5d0602b
commit 25d2e2e122
9 changed files with 26 additions and 13 deletions

View File

@@ -685,7 +685,8 @@ exports.filter_all_users = function (pred) {
return ret;
};
exports.get_realm_persons = function () {
exports.get_realm_users = function () {
// includes humans and bots from your realm
return Array.from(active_user_dict.values());
};
@@ -921,7 +922,7 @@ exports.get_people_for_stream_create = function () {
/*
If you are thinking of reusing this function,
a better option in most cases is to just
call `exports.get_realm_persons()` and then
call `exports.get_realm_users()` and then
filter out the "me" user yourself as part of
any other filtering that you are doing.