Browse Source

dont send profile photo to from_group contacts

hosting-provider
Evan Feenstra 5 years ago
parent
commit
18190b4596
  1. 4
      api/controllers/contacts.ts
  2. 4
      dist/api/controllers/contacts.js
  3. 2
      dist/api/controllers/contacts.js.map

4
api/controllers/contacts.ts

@ -86,7 +86,9 @@ const updateContact = async (req, res) => {
if (!shouldSendUpdatedSelf) return
// send updated owner info to others
const contactIds = await models.Contact.findAll({where:{deleted:false}}).map(c => c.id)
const contactIds = await models.Contact.findAll({
where:{deleted:false,fromGroup:false}
}).map(c => c.id)
if (contactIds.length == 0) return
helpers.sendContactKeys({

4
dist/api/controllers/contacts.js

@ -79,7 +79,9 @@ const updateContact = (req, res) => __awaiter(void 0, void 0, void 0, function*
if (!shouldSendUpdatedSelf)
return;
// send updated owner info to others
const contactIds = yield models_1.models.Contact.findAll({ where: { deleted: false } }).map(c => c.id);
const contactIds = yield models_1.models.Contact.findAll({
where: { deleted: false, fromGroup: false }
}).map(c => c.id);
if (contactIds.length == 0)
return;
helpers.sendContactKeys({

2
dist/api/controllers/contacts.js.map

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save