text: const fs = require('fs')
  
  exports.isLimit = function(sender, isPremium, isOwner, limitCount, _db){
      if (isOwner) return false
      if (isPremium) return false
      let found = false
      for (let i of _db) {
          if (i.id === sender) {
              let limits = i.limit
              if (limits >= limitCount) {
                  found = true
                  return true
              } else {
                  found = true
                  return false
              }
          }
      }
      if (found === false) {
          const obj = { id: sender, limit: 0 }
          _db.push(obj)
          fs.writeFileSync('./database/limit.json', JSON.stringify(_db, null, 2))
          return false
      }
  }
  exports.limitAdd = function(sender, _db){
      let found = false
  	Object.keys(_db).forEach((i) => {
  		if (_db[i].id === sender) {
  			found = i
  		}
  	})
  		if (found !== false) {
  			_db[found].limit += 1
  			fs.writeFileSync('./database/limit.json', JSON.stringify(_db, null, 2))
  		}
  }
  exports.getLimit = function(sender, limitCount, _db){
      let found = false
      Object.keys(_db).forEach((i) => {
          if (_db[i].id === sender) {
              found = i
          }
      })
      if (found !== false) {
          return limitCount - _db[found].limit
      } else {
          return limitCount
      }
  }
  exports.giveLimit = function(pemain, duit, _db){
      let position = false
      Object.keys(_db).forEach((i) => {
          if (_db[i].id === pemain) {
              position = i
          }
      })
      if (position !== false) {
          _db[position].limit -= duit
          fs.writeFileSync('./database/limit.json', JSON.stringify(_db, null, 2))
      } else {
          const njt = duit - duit - duit
          const bulim = ({
              id: pemain,
              limit: njt
                  })
          _db.push(bulim)
          fs.writeFileSync('./database/limit.json', JSON.stringify(_db, null, 2))
      }
  }
  exports.addBalance = function(sender, duit, _db){
      let position = false
      Object.keys(_db).forEach((i) => {
          if (_db[i].id === sender) {
              position = i
          }
      })
      if (position !== false) {
          _db[position].balance += duit
          fs.writeFileSync('./database/balance.json', JSON.stringify(_db, null, 2))
      } else {
          const bulin = ({
              id: sender,
              balance: duit
                  })
          _db.push(bulin)
          fs.writeFileSync('./database/balance.json', JSON.stringify(_db, null, 2))
      }
  }
  exports.kurangBalance = function(sender, duit, _db){
      let position = false
      Object.keys(_db).forEach((i) => {
          if (_db[i].id === sender) {
              position = i
          }
      })
      if (position !== false) {
          _db[position].balance -= duit
          fs.writeFileSync('./database/balance.json', JSON.stringify(_db, null, 2))
      }
  }
  exports.getBalance = function(sender, _db){
      let position = false
      Object.keys(_db).forEach((i) => {
          if (_db[i].id === sender) {
              position = i
          }
      })
      if (position !== false) {
          return _db[position].balance
      } else {
          return 0
      }
  }
  