mirror of https://github.com/zulip/zulip.git
Simplify condition for aborting people.reify().
Since it's basically impossible to add a person with an undefined full_name--even "skeleton" people--there is no need to check the full_name field to short circuit reify(), because it will always be defined. (imported from commit 3a30cfd583a040f7460739abea1604594c450ffe)
This commit is contained in:
parent
cbb5878477
commit
6ec72a290d
|
@ -89,9 +89,9 @@ exports.reify = function reify(person) {
|
|||
|
||||
var old_person = people_dict.get(person.email);
|
||||
|
||||
// Don't overwrite an already-reified person. If we have
|
||||
// a full name, we already have the full person object loaded
|
||||
if (old_person.full_name !== undefined && !old_person.skeleton) {
|
||||
// Only overwrite skeleton objects here. If the object
|
||||
// had already been reified, exit early.
|
||||
if (!old_person.skeleton) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue