Remove token from config file

This commit is contained in:
Cadence Ember 2024-09-13 23:47:11 +12:00
parent c0d92ea66d
commit cc7831a313
9 changed files with 11 additions and 22 deletions

View file

@ -10,7 +10,6 @@
*/
module.exports = async function(db) {
const config = require("../../../config")
const id = Buffer.from(config.discordToken.split(".")[0], "base64").toString()
const id = require("../../../addbot").id
db.prepare("UPDATE OR REPLACE sim SET user_id = ? WHERE user_id = '0'").run(id)
}

View file

@ -3,7 +3,6 @@
/**
* @typedef {Object} Passthrough
* @property {import("repl").REPLServer} repl
* @property {typeof import("./config")} config
* @property {import("./d2m/discord-client")} discord
* @property {import("heatsync").default} sync
* @property {import("better-sqlite3/lib/database")} db

View file

@ -5,7 +5,7 @@ const util = require("util")
const {addbot} = require("../addbot")
const passthrough = require("./passthrough")
const {discord, config, sync, db} = passthrough
const {discord, sync, db} = passthrough
const data = sync.require("../test/data")
const createSpace = sync.require("./d2m/actions/create-space")