2024-10-23 08:33:39 -07:00
|
|
|
const fs = require('fs')
|
|
|
|
const path = require('path')
|
|
|
|
|
2024-10-27 02:45:45 -07:00
|
|
|
const configPath = path.join(__dirname, 'variables.json')
|
2024-10-23 08:33:39 -07:00
|
|
|
|
2024-10-27 02:45:45 -07:00
|
|
|
class ExtraFileVerification {
|
2024-10-23 08:33:39 -07:00
|
|
|
constructor() {
|
|
|
|
this.config = this.loadConfig()
|
|
|
|
}
|
|
|
|
|
|
|
|
loadConfig() {
|
|
|
|
const rawData = fs.readFileSync(configPath)
|
|
|
|
return JSON.parse(rawData.toString())
|
|
|
|
}
|
|
|
|
|
|
|
|
get status() {
|
2024-10-27 02:45:45 -07:00
|
|
|
return this.config.extraFileVerifActivated
|
2024-10-23 08:33:39 -07:00
|
|
|
}
|
|
|
|
|
2024-10-24 09:00:00 -07:00
|
|
|
get type() {
|
2024-10-23 08:33:39 -07:00
|
|
|
return this.config.menuVisibility
|
|
|
|
}
|
2024-10-26 07:26:54 -07:00
|
|
|
|
|
|
|
get debug() {
|
|
|
|
return this.config.debug
|
|
|
|
}
|
2024-10-23 08:33:39 -07:00
|
|
|
}
|
|
|
|
|
2024-10-27 02:47:55 -07:00
|
|
|
const ExtraFileVerificationInstance = new ExtraFileVerification()
|
|
|
|
module.exports = ExtraFileVerificationInstance
|