module.exports = async function importOldData(db, run, get, all) { oldData = require("../snowflakes.json"); for (const key in oldData) { let actor = oldData[key][0]; run("INSERT INTO badActors (id, reportedBy, comment, timestamp) VALUES (?, ?, ?, ?)", [ key, actor.author.id, actor.orig_content, new Date(actor.created_at).getTime() ]) } }