Skip to content

Commit

Permalink
[FIX] Error during data export for DMs (#17577)
Browse files Browse the repository at this point in the history
  • Loading branch information
mtmr0x authored May 8, 2020
1 parent 2ebfcd4 commit 75743f2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/user-data-download/server/cronProcessDownloads.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const loadUserSubscriptions = function(exportOperation) {
const roomId = subscription.rid;
const roomData = Rooms.findOneById(roomId);
const roomName = roomData && roomData.name && subscription.t !== 'd' ? roomData.name : roomId;
const [userId] = subscription.t === 'd' ? roomId.uids.filter((uid) => uid !== exportUserId) : [null];
const [userId] = subscription.t === 'd' ? roomData.uids.filter((uid) => uid !== exportUserId) : [null];
const fileName = exportOperation.fullExport ? roomId : roomName;
const fileType = exportOperation.fullExport ? 'json' : 'html';
const targetFile = `${ fileName }.${ fileType }`;
Expand Down

0 comments on commit 75743f2

Please sign in to comment.