Effect CommunityEC
Effect Community3y ago
15 replies
spaethnl

Error Handling in Effect-Bot's DocsLookup

This line Effect.bind("embed", ({ key, docs }) => docs.map[key].embed), (see: https://github.com/Effect-TS/discord-bot/blob/9911b3e8e68e35c716d10e9a47d852c85398eff8/src/DocsLookup.ts#L109) in effect-bot can potentially error due to docs.map[key] being empty. Can you Fail an effect from within bind, or should it be checked before that line?
Was this page helpful?