diff --git a/package.json b/package.json index f8527b5e..e190fbd5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "xiao", - "version": "158.0.0", + "version": "158.0.1", "description": "Your personal server companion.", "main": "Xiao.js", "scripts": { @@ -75,6 +75,7 @@ "sagiri": "^4.3.0", "semver": "^7.7.2", "sherlockjs": "^1.4.2", + "simdjson": "^0.9.2", "stackblur-canvas": "^2.7.0", "text-diff": "^1.0.1", "tictactoe-minimax-ai": "github:marianoheller/tic-tac-toe-minimax", diff --git a/structures/JeopardyScrape.js b/structures/JeopardyScrape.js index abb77008..4e192191 100644 --- a/structures/JeopardyScrape.js +++ b/structures/JeopardyScrape.js @@ -1,6 +1,7 @@ const request = require('node-superfetch'); const cheerio = require('cheerio'); const fs = require('fs'); +const simdjson = require('simdjson'); const path = require('path'); const { checkFileExists } = require('../util/Util'); const rounds = ['jeopardy_round', 'double_jeopardy_round', 'final_jeopardy_round']; @@ -66,7 +67,7 @@ module.exports = class JeopardyScrape { async importData() { const read = await fs.promises.readFile(path.join(__dirname, '..', 'jeopardy.json'), { encoding: 'utf8' }); - const file = JSON.parse(read); + const file = simdjson.parse(read); if (typeof file !== 'object' || Array.isArray(file)) return null; if (!file.clues || !file.gameIDs || !file.seasons) return null; for (const season of file.seasons) {