diff --git a/commands/match-command.ts b/commands/match-command.ts index fbcb279..def0185 100644 --- a/commands/match-command.ts +++ b/commands/match-command.ts @@ -1,6 +1,6 @@ import { db } from '../common'; import 'dotenv/config'; -import questions from '../questions.json'; +import { questions } from '../questions'; import { sendQuestion } from './test-command'; import { ChatInputCommandInteraction } from "discord.js"; diff --git a/commands/test-command.ts b/commands/test-command.ts index 5370979..7027682 100644 --- a/commands/test-command.ts +++ b/commands/test-command.ts @@ -1,7 +1,7 @@ import { ActionRowBuilder, ButtonBuilder, ButtonStyle, EmbedBuilder, SlashCommandBuilder, Guild, Role, User, TextChannel, ChatInputCommandInteraction } from 'discord.js'; import cron from 'cron'; import 'dotenv/config'; -import questions from '../questions.json'; +import { questions } from '../questions'; import { db, client } from "../common"; import { encrypt, decrypt } from "../encryptionUtils"; import { findMatchingUser } from "../functions/findMatchingUser"; diff --git a/functions/conversationStarter.ts b/functions/conversationStarter.ts index 8bec815..65eef4a 100644 --- a/functions/conversationStarter.ts +++ b/functions/conversationStarter.ts @@ -1,5 +1,5 @@ import { EmbedBuilder, User } from 'discord.js'; -import questions from '../questions.json'; +import { questions } from '../questions'; import { CronJob } from "cron"; import { client, db } from "../common"; diff --git a/questions.json b/questions.ts similarity index 99% rename from questions.json rename to questions.ts index a723eab..aaabfbe 100644 --- a/questions.json +++ b/questions.ts @@ -1,4 +1,4 @@ -[ +export const questions = [ { "question": "Auf allen Autobahnen soll ein generelles Tempolimit gelten.", "tag": ["Verkehrssicherheit", " Klimawandel"] }, { "question": "Deutschland soll seine Verteidigungsausgaben erhöhen.", "tag": "Verteidigungspolitik" }, { "question": "Bei Bundestagswahlen sollen auch Jugendliche ab 16 Jahren wählen dürfen.", "tag": ["Wahlalter", "Demokratie"] },