Skip to content

Commit

Permalink
Allow async onload functions
Browse files Browse the repository at this point in the history
  • Loading branch information
brandoningli committed Dec 27, 2023
1 parent ac536ba commit 9daec6b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -139,4 +139,7 @@ dist

# Plugins (These are to be handled in separate repos)
plugins/*
!plugins/README.md
!plugins/README.md

# Analytics DBs
*.sqlite
2 changes: 1 addition & 1 deletion src/pluginManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ function load(bot) {

if (loaded && module?.onLoad) {
logger.log("debug", `Running "${module.NAME}" onLoad function...`);
module.onLoad(bot);
await module.onLoad(bot);
}
});

Expand Down

0 comments on commit 9daec6b

Please sign in to comment.