stuff
This commit is contained in:
parent
79e036d288
commit
8ec095192a
|
@ -686,13 +686,13 @@ var PluginRepo = (_ => {
|
||||||
bodyCopy = body.replace(/}/g, "}\n");
|
bodyCopy = body.replace(/}/g, "}\n");
|
||||||
}
|
}
|
||||||
let bodyWithoutSpecial = bodyCopy.replace(/\n|\r|\t/g, "");
|
let bodyWithoutSpecial = bodyCopy.replace(/\n|\r|\t/g, "");
|
||||||
let configreg = /(module\.exports|config)\s*=\s*\{["'`]*info["'`]*\s*:\s*/i.exec(bodyWithoutSpecial);
|
let configreg = /(\.exports|config)\s*=\s*\{["'`]*info["'`]*\s*:\s*/i.exec(bodyWithoutSpecial);
|
||||||
if (url != "https://raw.githubusercontent.com/mwittrien/BetterDiscordAddons/master/Plugins/PluginRepo/PluginRepo.plugin.js" && configreg) {
|
if (url != "https://raw.githubusercontent.com/mwittrien/BetterDiscordAddons/master/Plugins/PluginRepo/PluginRepo.plugin.js" && configreg) {
|
||||||
try {
|
try {
|
||||||
extractConfigInfo(plugin, JSON.parse('{"info":' + bodyWithoutSpecial.substring(configreg.index).split(configreg[0])[1].split("};")[0] + '}'));
|
extractConfigInfo(plugin, JSON.parse('{"info":' + bodyWithoutSpecial.substring(configreg.index).split(configreg[0])[1].split("};")[0].split("}},")[0] + '}'));
|
||||||
}
|
}
|
||||||
catch (err) {
|
catch (err) {
|
||||||
try {extractConfigInfo(plugin, JSON.parse(('{"info":' + bodyWithoutSpecial.substring(configreg.index).split(configreg[0])[1].split("};")[0] + '}').replace(/,/g, ',"').replace(/:/g, '":').replace(/{/g, '{"').replace(/""/g, '"').replace(/" /g, ' ').replace(/,"{/g, ',{').replace(/,"\[/g, ',[').replace(/":\/\//g, ':\/\/')));}
|
try {extractConfigInfo(plugin, JSON.parse(('{"info":' + bodyWithoutSpecial.substring(configreg.index).split(configreg[0])[1].split("};")[0].split("}},")[0] + '}').replace(/,/g, ',"').replace(/:/g, '":').replace(/{/g, '{"').replace(/""/g, '"').replace(/" /g, ' ').replace(/,"{/g, ',{').replace(/,"\[/g, ',[').replace(/":\/\//g, ':\/\/')));}
|
||||||
catch (err2) {}
|
catch (err2) {}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1692,7 +1692,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="REPLACE_CLASS_inviteguilddetail REPLACE_CLASS_weightmedium">
|
<div class="REPLACE_CLASS_inviteguilddetail REPLACE_CLASS_weightmedium">
|
||||||
<div class="REPLACE_CLASS_invitestatuscounts">
|
<div class="REPLACE_CLASS_invitestatuscounts">
|
||||||
<i class="REPLACE_CLASS_statusonline"></i>
|
<i class="REPLACE_CLASS_invitestatusonline"></i>
|
||||||
<span class="REPLACE_CLASS_invitecount"><strong>50</strong> Online</span>
|
<span class="REPLACE_CLASS_invitecount"><strong>50</strong> Online</span>
|
||||||
<i class="REPLACE_CLASS_invitestatusoffline"></i>
|
<i class="REPLACE_CLASS_invitestatusoffline"></i>
|
||||||
<span class="REPLACE_CLASS_invitecount"><strong>100</strong> Members</span>
|
<span class="REPLACE_CLASS_invitecount"><strong>100</strong> Members</span>
|
||||||
|
@ -1764,7 +1764,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="REPLACE_CLASS_inviteguilddetail REPLACE_CLASS_weightmedium">
|
<div class="REPLACE_CLASS_inviteguilddetail REPLACE_CLASS_weightmedium">
|
||||||
<div class="REPLACE_CLASS_invitestatuscounts">
|
<div class="REPLACE_CLASS_invitestatuscounts">
|
||||||
<i class="REPLACE_CLASS_statusonline"></i>
|
<i class="REPLACE_CLASS_invitestatusonline"></i>
|
||||||
<span class="REPLACE_CLASS_invitecount">
|
<span class="REPLACE_CLASS_invitecount">
|
||||||
<strong>50</strong> Online</span>
|
<strong>50</strong> Online</span>
|
||||||
<i class="REPLACE_CLASS_invitestatusoffline"></i>
|
<i class="REPLACE_CLASS_invitestatusoffline"></i>
|
||||||
|
|
Loading…
Reference in New Issue