ctr / Kamihime Project R - Eliminate raid connection error popup

// ==UserScript==
// @name         Kamihime Project R - Eliminate raid connection error popup
// @description  Eliminates raid connection error popup
// @license      MIT
// @match        https://cf.r.kamihimeproject.dmmgames.com/front/cocos2d-proj/components-pc/game/app.html
// @run-at       document-start
// ==/UserScript==

(function() {

    var interval = setInterval(function() {
        if (typeof kh !== 'undefined' && kh.HttpConnection) {
            clearInterval(interval);

            kh.HttpConnection.prototype._openRetryMessagePopup = function(orgArguments, res) {
                this._retryAfterMinWait(orgArguments, res, 0);
            }

        }
    }, 10);

})();