Skip to content

Conversation

garrrikkotua
Copy link
Contributor

@garrrikkotua garrrikkotua commented Sep 12, 2023

Changes proposed ✍️

What

🤖 Generated by Copilot at 8e72a5f

Improved error handling for Discord integration. Added logic to getMessage function to handle missing or forbidden messages and return null instead of throwing an error.

🤖 Generated by Copilot at 8e72a5f

Oh we're the coders of the sea, and we work with APIs
We handle errors gracefully, and we test our code with ease
When we call getMessage, we don't want to see a crash
So we check for 404s, and return null for the trash

Why

How

🤖 Generated by Copilot at 8e72a5f

  • Add error handling for 404 status code from Discord API when fetching messages (link, link)

Checklist ✅

  • Label appropriately with Feature, Improvement, or Bug.
  • Add screehshots to the PR description for relevant FE changes
  • New backend functionality has been unit-tested.
  • API documentation has been updated (if necessary) (see docs on API documentation).
  • Quality standards are met.

@garrrikkotua garrrikkotua merged commit 367b919 into main Sep 12, 2023
@garrrikkotua garrrikkotua deleted the fix/discord-404 branch September 12, 2023 13:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants