wait for mongoose to connect
parent
d696dcf804
commit
4f07d6ece2
|
@ -77,8 +77,7 @@ export default class Client extends eris.Client {
|
|||
}
|
||||
|
||||
public async loadDatabase() {
|
||||
mongoose.connect(this.config.mongoDB, {
|
||||
minPoolSize: 50,
|
||||
await mongoose.connect(this.config.mongoDB, {
|
||||
});
|
||||
|
||||
const statMessages = await this.db.mongo.Stat.findOne({ name: 'messages' });
|
||||
|
|
Loading…
Reference in New Issue