Skip to content

Privacy Badger blocks the Discord widget on the frontpage #968

Description

@IZEDx

const req = new XMLHttpRequest();
req.open("GET", "https://discord.com/api/guilds/817075418054000661/widget.json");
req.onload = () => {
const data = JSON.parse(req.responseText);
discord.value.name = data.name;
discord.value.invite = data.instant_invite;
discord.value.count = data.presence_count;
};
req.send();

This request is being identified as a tracker by Privacy Badger and thus blocked, resulting in the Discord Invite being unavailable. Took me a while to figure out what was causing this.

There should be a fallback to the actual discord invite link when the widget.json can't be requested.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions