fixed object destructuring to fallback to {} when meta.team is null (#2158)

This commit is contained in:
Niklas Haug
2021-04-26 12:00:26 +02:00
committed by GitHub
parent 285f7bbeb5
commit 78996937ce

View File

@@ -13,7 +13,7 @@ export const applyPageFilters = (conversation, filters) => {
labels: chatLabels = [], labels: chatLabels = [],
meta = {}, meta = {},
} = conversation; } = conversation;
const { team = {} } = meta; const team = meta.team || {};
const { id: chatTeamId } = team; const { id: chatTeamId } = team;
const filterByStatus = chatStatus === status; const filterByStatus = chatStatus === status;
let shouldFilter = filterByStatus; let shouldFilter = filterByStatus;