Skip to content

Commit

Permalink
fix: guard on non-existent result (#2931)
Browse files Browse the repository at this point in the history
Co-authored-by: Sébastien Levert <sebastienlevert@users.noreply.github.com>
  • Loading branch information
gavinbarron and sebastienlevert authored Jan 4, 2024
1 parent 81d124b commit 981e6f9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -746,7 +746,7 @@ export class MgtTeamsChannelPicker extends MgtTemplatedComponent {
for (const team of teams) {
const channelsForTeam = responses.get(team.id);
// skip over any teams that don't have channels
if (!channelsForTeam.content?.value?.length) continue;
if (!channelsForTeam?.content?.value?.length) continue;
this.items.push({
item: team,
channels: channelsForTeam.content.value.map(c => ({ item: c }))
Expand Down

0 comments on commit 981e6f9

Please sign in to comment.