Fix:
- Fix sourceURL for client bundle - Fix export getters throwing errors
This commit is contained in:
parent
528ababa9f
commit
fbff8e2e52
|
@ -60,6 +60,7 @@ export default class BetterDiscord {
|
|||
return false;
|
||||
}
|
||||
})();
|
||||
//# sourceURL=betterdiscord/renderer.js
|
||||
`);
|
||||
|
||||
if (!success) return; // TODO: cut a fatal log
|
||||
|
|
|
@ -159,14 +159,18 @@ export default class WebpackModules {
|
|||
for (let i = 0; i < indices.length; i++) {
|
||||
const index = indices[i];
|
||||
if (!modules.hasOwnProperty(index)) continue;
|
||||
const module = modules[index];
|
||||
|
||||
let module = null;
|
||||
try {module = modules[index]} catch {continue;};
|
||||
|
||||
const {exports} = module;
|
||||
if (!exports || exports === window || exports === document.documentElement) continue;
|
||||
|
||||
if (typeof(exports) === "object" && searchExports) {
|
||||
if (typeof(exports) === "object" && searchExports && exports[Symbol.toStringTag] !== "DOMTokenList") {
|
||||
for (const key in exports) {
|
||||
let foundModule = null;
|
||||
const wrappedExport = exports[key];
|
||||
let foundModule = null, wrappedExport = null;
|
||||
try {wrappedExport = exports[key];} catch {continue;}
|
||||
|
||||
if (!wrappedExport) continue;
|
||||
if (wrappedFilter(wrappedExport, module, index)) foundModule = wrappedExport;
|
||||
if (!foundModule) continue;
|
||||
|
@ -481,4 +485,4 @@ export default class WebpackModules {
|
|||
}
|
||||
}
|
||||
|
||||
WebpackModules.initialize();
|
||||
WebpackModules.initialize();
|
||||
|
|
Loading…
Reference in New Issue