Update 0BDFDB.plugin.js
This commit is contained in:
parent
33ca5f2b0c
commit
18b1826b95
|
@ -2,7 +2,7 @@
|
||||||
* @name BDFDB
|
* @name BDFDB
|
||||||
* @author DevilBro
|
* @author DevilBro
|
||||||
* @authorId 278543574059057154
|
* @authorId 278543574059057154
|
||||||
* @version 2.5.3
|
* @version 2.5.4
|
||||||
* @description Required Library for DevilBro's Plugins
|
* @description Required Library for DevilBro's Plugins
|
||||||
* @invite Jx3TjNS
|
* @invite Jx3TjNS
|
||||||
* @donate https://www.paypal.me/MircoWittrien
|
* @donate https://www.paypal.me/MircoWittrien
|
||||||
|
@ -19,7 +19,7 @@ module.exports = (_ => {
|
||||||
"info": {
|
"info": {
|
||||||
"name": "BDFDB",
|
"name": "BDFDB",
|
||||||
"author": "DevilBro",
|
"author": "DevilBro",
|
||||||
"version": "2.5.3",
|
"version": "2.5.4",
|
||||||
"description": "Required Library for DevilBro's Plugins"
|
"description": "Required Library for DevilBro's Plugins"
|
||||||
},
|
},
|
||||||
"rawUrl": "https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js"
|
"rawUrl": "https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js"
|
||||||
|
@ -8506,19 +8506,27 @@ module.exports = (_ => {
|
||||||
if (funcString && funcString.indexOf(".page") > -1 && funcString.indexOf(".section") > -1 && funcString.indexOf(".objectType") > -1) {
|
if (funcString && funcString.indexOf(".page") > -1 && funcString.indexOf(".section") > -1 && funcString.indexOf(".objectType") > -1) {
|
||||||
const returnValue = exports.default({});
|
const returnValue = exports.default({});
|
||||||
if (returnValue && returnValue.props && returnValue.props.object == BDFDB.DiscordConstants.AnalyticsObjects.CONTEXT_MENU) {
|
if (returnValue && returnValue.props && returnValue.props.object == BDFDB.DiscordConstants.AnalyticsObjects.CONTEXT_MENU) {
|
||||||
for (const type in PluginStores.contextChunkObserver) {
|
for (const type in PluginStores.contextChunkObserver) if (PluginStores.contextChunkObserver[type].filter(returnValue.props.children)) {
|
||||||
if (PluginStores.contextChunkObserver[type].filter(returnValue.props.children)) {
|
exports.__BDFDB_ContextMenuWrapper_Patch_Name = exports.__BDFDB_ContextMenu_Patch_Name;
|
||||||
exports.__BDFDB_ContextMenuWrapper_Patch_Name = exports.__BDFDB_ContextMenu_Patch_Name;
|
found = true;
|
||||||
found = true;
|
if (PluginStores.contextChunkObserver[type].modules.indexOf(exports) == -1) PluginStores.contextChunkObserver[type].modules.push(exports);
|
||||||
if (PluginStores.contextChunkObserver[type].modules.indexOf(exports) == -1) PluginStores.contextChunkObserver[type].modules.push(exports);
|
for (const plugin of PluginStores.contextChunkObserver[type].query) Internal.patchContextMenu(plugin, type, exports);
|
||||||
for (const plugin of PluginStores.contextChunkObserver[type].query) Internal.patchContextMenu(plugin, type, exports);
|
break;
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!found) for (const type in PluginStores.contextChunkObserver) {
|
if (!found) for (const type in PluginStores.contextChunkObserver) {
|
||||||
if (PluginStores.contextChunkObserver[type].filter(exports)) {
|
if (PluginStores.contextChunkObserver[type].filter(exports)) {
|
||||||
|
found = true;
|
||||||
|
if (PluginStores.contextChunkObserver[type].modules.indexOf(exports) == -1) PluginStores.contextChunkObserver[type].modules.push(exports);
|
||||||
|
for (const plugin of PluginStores.contextChunkObserver[type].query) Internal.patchContextMenu(plugin, type, exports);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!found) {
|
||||||
|
let moduleString = require.m[id] && typeof require.m[id].toString == "function" && require.m[id].toString();
|
||||||
|
if (moduleString) for (const type in PluginStores.contextChunkObserver) if (moduleString.indexOf(`="${type}`) > -1) {
|
||||||
|
found = true;
|
||||||
if (PluginStores.contextChunkObserver[type].modules.indexOf(exports) == -1) PluginStores.contextChunkObserver[type].modules.push(exports);
|
if (PluginStores.contextChunkObserver[type].modules.indexOf(exports) == -1) PluginStores.contextChunkObserver[type].modules.push(exports);
|
||||||
for (const plugin of PluginStores.contextChunkObserver[type].query) Internal.patchContextMenu(plugin, type, exports);
|
for (const plugin of PluginStores.contextChunkObserver[type].query) Internal.patchContextMenu(plugin, type, exports);
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue