Twitch Un-raid

Go back to the channel where you were a few minutes after a raid

// ==UserScript==
// @name         Twitch Un-raid
// @version      1
// @description  Go back to the channel where you were a few minutes after a raid
// @author       jmatg1
// @match        https://twitch.tv
// @license MIT
// @namespace https://greasyfork.org/users/843476
// ==/UserScript==

(function() {
    function checkPage(){
        if(window.location.href.includes('?referrer=raid')){
            history.back()
        }
    }
    setTimeout(checkPage, 3*1000);
})();