Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't try to parse Discord channels that are not accessible #1568

Merged
merged 1 commit into from
Sep 27, 2023

Conversation

garrrikkotua
Copy link
Contributor

@garrrikkotua garrrikkotua commented Sep 27, 2023

Changes proposed ✍️

What

🤖 Generated by Copilot at 3984412

This pull request enhances the Discord integration by filtering the stream based on the user's channel permissions. It adds a new file processStream.ts that uses the axios module to query the Discord API and determine which channels the user can access.

🤖 Generated by Copilot at 3984412

To filter the Discord stream
The pull request adds some scheme
It uses axios
To check the user's access
And stores the channels in arrays extreme

Why

How

🤖 Generated by Copilot at 3984412

  • Import axios module to make HTTP requests to Discord API (link)
  • Declare arrays to store allowed and forbidden channels based on permissions (link)
  • Check each channel's permission by making GET requests to Discord API and add to corresponding array (link)
  • Filter threads by checking parent channel's permission and cache forum threads (link)
  • Publish only allowed channels to stream and stream data (link, link)
  • Update settings to include forbidden channels (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 e635f19 into main Sep 27, 2023
9 checks passed
@garrrikkotua garrrikkotua deleted the fix/discord-allowed-channels branch September 27, 2023 15:20
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.

None yet

1 participant