mirror of
https://github.com/JannisX11/blockbench.git
synced 2024-11-27 04:21:46 +08:00
Catch error when loading invalid plugin from file
This commit is contained in:
parent
315cb87e6d
commit
404b232ebd
@ -333,7 +333,9 @@ class Plugin {
|
||||
this.tags.safePush('Local');
|
||||
|
||||
if (isApp) {
|
||||
let content = await runPluginFile(file.path, this.id);
|
||||
let content = await runPluginFile(file.path, this.id).catch((error) => {
|
||||
console.error(error);
|
||||
});
|
||||
if (content) {
|
||||
if (window.plugin_data) {
|
||||
scope.id = (plugin_data && plugin_data.id)||pathToName(file.path)
|
||||
|
Loading…
Reference in New Issue
Block a user