2020-04-08 16:27:34 +02:00
|
|
|
class Provider {
|
|
|
|
|
2020-04-08 18:08:46 +02:00
|
|
|
constructor(manager, config) {
|
|
|
|
|
|
|
|
if(!config) throw new Error('No config file provided!');
|
|
|
|
if(config && (!config.database || !config.url)) throw new Error('Invalid config file provided!');
|
|
|
|
|
|
|
|
this.manager = manager;
|
|
|
|
this.config = config;
|
|
|
|
this.db;
|
|
|
|
this.loaded = false;
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2020-04-08 16:27:34 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
module.exports = Provider;
|