chore: eslint function-paren-newline

This commit is contained in:
Peter Jaszkowiak
2021-02-04 00:12:32 -07:00
committed by Julian Lam
parent dab3b23575
commit 62869bae3d
12 changed files with 49 additions and 32 deletions

View File

@@ -79,8 +79,10 @@ async function getRoomMessages(uid, roomId) {
let data = [];
await batch.processSortedSet(`uid:${uid}:chat:room:${roomId}:mids`, async (mids) => {
const messageData = await db.getObjects(mids.map(mid => `message:${mid}`));
data = data.concat(messageData.filter(m => m && m.fromuid === uid && !m.system)
.map(m => ({ content: m.content, timestamp: m.timestamp }))
data = data.concat(
messageData
.filter(m => m && m.fromuid === uid && !m.system)
.map(m => ({ content: m.content, timestamp: m.timestamp }))
);
}, { batch: 500, interval: 1000 });
return data;