Skip to content

Instantly share code, notes, and snippets.

@renato425
Created August 11, 2021 11:42
Show Gist options
  • Save renato425/68b5b0e740721feaecb11a95bdab93d9 to your computer and use it in GitHub Desktop.
Save renato425/68b5b0e740721feaecb11a95bdab93d9 to your computer and use it in GitHub Desktop.
const SimpleDBJson = require('simple-db-json')
const db = new SimpleDBJson('db', '\t')
//users é um objeto
if (db.get('users').has('858573520875421746').this == true) {
let money = db.get('users').get('858573520875421746').this.money
db.get('users').get('858573520875421746').set('money', money + 500)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment