fix folder opening
This commit is contained in:
parent
73cae52f9b
commit
8d25e33a2e
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -144,7 +144,7 @@ export default new class ContentManager {
|
|||
content = "";
|
||||
}
|
||||
else {
|
||||
// Utils.warn("Module Not Exported", `${meta.name}, please start setting module.exports`);
|
||||
Utils.warn("Module Not Exported", `${meta.name}, please start setting module.exports`);
|
||||
content += `\nmodule.exports = ${JSON.stringify(meta)};\nmodule.exports.type = ${meta.exports || meta.name};`;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -33,7 +33,9 @@ export default class CardList extends BDV2.reactComponent {
|
|||
}
|
||||
|
||||
openFolder() {
|
||||
require("electron").shell.openItem(this.isPlugins ? ContentManager.pluginsFolder : ContentManager.themesFolder);
|
||||
const shell = require("electron").shell;
|
||||
const open = shell.openPath || shell.openItem;
|
||||
open(this.isPlugins ? ContentManager.pluginsFolder : ContentManager.themesFolder);
|
||||
}
|
||||
|
||||
edit(name) {
|
||||
|
|
|
@ -26,4 +26,12 @@ export default class V2C_Scroller extends BDV2.reactComponent {
|
|||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const originalRender = V2C_Scroller.prototype.render;
|
||||
Object.defineProperty(V2C_Scroller.prototype, "render", {
|
||||
enumerable: false,
|
||||
configurable: false,
|
||||
set: function() {console.warn("Addon policy for plugins #5 https://github.com/rauenzi/BetterDiscordApp/wiki/Addon-Policies#plugins");},
|
||||
get: () => originalRender
|
||||
});
|
Loading…
Reference in New Issue