Bypass acortalink.me

Bypass acortalink.me link shortener

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name        Bypass acortalink.me
// @namespace   Violentmonkey Scripts
// @match       *://acortalink.me/*
// @grant       none
// @version     2.1
// @author      Rust1667
// @description Bypass acortalink.me link shortener
// @run-at     document-start
// ==/UserScript==

function bypassAcortaLink() {
    let acorta = setInterval(() => {
        let script = document.querySelector('body > script');
        if (script) {
            let text = script.text.trim();
            let lines = text.split('\n');
            let i = lines.findIndex(x => x.includes('acortalink.me'));
            let link = lines[i + 2]?.trim().split(',')[6]?.trim();

            if (link && window[link]) {
                clearInterval(acorta);

                // Redirect to the link
                window.location.href = window[link];

                //Open alert if it is a magnet link
                if (window[link].startsWith("magnet:?")) {
                  alert(window[link]);
                }
            }
        }
    }, 100);
}

bypassAcortaLink();