Files
liberama/server/core/BookUpdateChecker/BUCServer.js
2022-07-16 13:16:57 +07:00

24 lines
515 B
JavaScript

let instance = null;
//singleton
class BUCServer {
constructor(config) {
if (!instance) {
this.config = Object.assign({}, config);
this.config.tempDownloadDir = `${config.tempDir}/download`;
fs.ensureDirSync(this.config.tempDownloadDir);
this.down = new FileDownloader(config.maxUploadFileSize);
instance = this;
}
return instance;
}
async main() {
}
}
module.exports = BUCServer;