Browse Source

inlude deleted msgs in getMessages

bugfix/timeout-logging
Evan Feenstra 5 years ago
parent
commit
ed9d9e7e3b
  1. 5
      api/controllers/messages.ts
  2. 5
      dist/api/controllers/messages.js
  3. 2
      dist/api/controllers/messages.js.map

5
api/controllers/messages.ts

@ -34,7 +34,10 @@ const getMessages = async (req, res) => {
let confirmedMessagesWhere = {
updated_at: { [Op.gte]: dateToReturn },
status: constants.statuses.received,
status: {[Op.or]: [
constants.statuses.received,
constants.statuses.deleted
]},
sender: owner.id
}

5
dist/api/controllers/messages.js

@ -40,7 +40,10 @@ const getMessages = (req, res) => __awaiter(void 0, void 0, void 0, function* ()
};
let confirmedMessagesWhere = {
updated_at: { [sequelize_1.Op.gte]: dateToReturn },
status: constants.statuses.received,
status: { [sequelize_1.Op.or]: [
constants.statuses.received,
constants.statuses.deleted
] },
sender: owner.id
};
// if (chatId) {

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

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