UNPKG

ysteelx.db

Version:

İndirilebilir Database Modülü

19 lines (14 loc) 525 B
const fs = require('fs') const read = (files) => JSON.parse(fs.readFileSync(files)) const chalk = require('chalk') //tanım end 31 // hatalar 31 const valueerr = chalk.red('[YSteelX.DB] Value Girmelisin!') const interr = chalk.red('[YSteelX.DB] Value Integer Olmalıdır') const undefinederr = chalk.red('[YSteelX.DB] Böyle Bir Veri Olmadığı İçin İşlem Geçersiz') // hatalar end 31 function has(userData) { const data = read('./database.json') return data[userData] ? true : false } module.exports = has