refactor: Extract people.maybe_incr_recipient_count().

This logic used to be in extract_people_from_message(), but
we are deprecating extract_people_from_message(), whereas
the maybe_incr_recipient_count() function has logic that we
want to keep.
This commit is contained in:
Steve Howell
2017-11-06 06:48:44 -08:00
committed by Tim Abbott
parent c291c74e45
commit 294a1fb8f8
3 changed files with 67 additions and 7 deletions

View File

@@ -123,6 +123,7 @@ exports.add_message_metadata = function (message) {
exports.set_message_booleans(message, message.flags);
people.extract_people_from_message(message);
people.maybe_incr_recipient_count(message);
var sender = people.get_person_from_user_id(message.sender_id);
if (sender) {