Skip to content

Commit

Permalink
fix: reward missing sort tags throws error (crowbartools#2861)
Browse files Browse the repository at this point in the history
  • Loading branch information
dennisrijsdijk committed Oct 18, 2024
1 parent db8aa59 commit 5fca0ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/backend/effects/builtin/update-channel-reward.ts
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ const model: EffectType<EffectMeta> = {
}

const rewards = Object.values(channelRewardsManager.channelRewards as Record<string, RewardWithTags>)
.filter(reward => reward.sortTags.includes(effect.sortTagId) && reward.manageable);
.filter(reward => reward.sortTags?.includes(effect.sortTagId) && reward.manageable);

const promises: Promise<SavedChannelReward>[] = [];

Expand Down

0 comments on commit 5fca0ae

Please sign in to comment.