Browse Source

log c.fromGroup

bugfix/timeout-logging
Evan Feenstra 4 years ago
parent
commit
9d4f40926c
  1. 5
      api/controllers/contacts.ts
  2. 5
      dist/api/controllers/contacts.js
  3. 2
      dist/api/controllers/contacts.js.map

5
api/controllers/contacts.ts

@ -81,7 +81,10 @@ export const updateContact = async (req, res) => {
// else:
// send updated owner info to others!
const contactIds = await models.Contact.findAll({where:{deleted:false}})
.filter(c=> !c.fromGroup && c.id!==1 && c.publicKey).map(c=> c.id)
.filter(c=> {
console.log(c.alias,c.fromGroup,typeof c.fromGroup)
return !c.fromGroup && c.id!==1 && c.publicKey
}).map(c=> c.id)
if (contactIds.length == 0) return
console.log("=> send contact_key to", contactIds)

5
dist/api/controllers/contacts.js

@ -76,7 +76,10 @@ exports.updateContact = (req, res) => __awaiter(void 0, void 0, void 0, function
// else:
// send updated owner info to others!
const contactIds = yield models_1.models.Contact.findAll({ where: { deleted: false } })
.filter(c => !c.fromGroup && c.id !== 1 && c.publicKey).map(c => c.id);
.filter(c => {
console.log(c.alias, c.fromGroup, typeof c.fromGroup);
return !c.fromGroup && c.id !== 1 && c.publicKey;
}).map(c => c.id);
if (contactIds.length == 0)
return;
console.log("=> send contact_key to", contactIds);

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

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