DGG Embed Bans

From [STAGING] Destiny Wiki
Revision as of 22:05, 29 July 2023 by Nado (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

In July 2023 a policy was introduced in DGG blocking Destiny's livestream embeds with the objective of increasing Kick.com online chat engagement.

There are currently no workarounds for the embed block BINGQILING

(function() {
    'use strict';

    const dataProperty = Object.getOwnPropertyDescriptor(MessageEvent.prototype, 'data');
    const dataGetter = dataProperty.get;

    dataProperty.get = function() {
        let data = dataGetter.call(this);

        if (!this.target instanceof WebSocket) {
            return data;
        }

        const json = JSON.parse(data);

        switch (json.type) {
            case 'dggApi:bannedEmbeds':
                json.data = [];
                data = JSON.stringify(json);
                break;
        }

        return data;
    }

    Object.defineProperty(MessageEvent.prototype, 'data', dataProperty);
})();