a fix for one of the better discord plugins

in #coding5 months ago

if you use the openlinksInDiscord plugin or wish to I know of a way to make it work in the latest version.

open the plugin file and replace line 72 with this

            if(e.target.localName == "a" && e.target.href && e.target.href.startsWith("http") && e.target.parentElement !== undefined && !e.target.parentElement.className.includes("channel") && !e.target.href.includes("/channels/")) {

the original code never checked if parentElement was null