From 1f5f5621c3ff963e6eb7f477bd69b6a127ba0ab0 Mon Sep 17 00:00:00 2001 From: Baipyrus Date: Mon, 29 Jan 2024 00:32:32 +0100 Subject: [PATCH] added voice channels to database --- database.js | 4 +++- models/voiceChannel.js | 10 ++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 models/voiceChannel.js diff --git a/database.js b/database.js index 607751b..ab1b792 100644 --- a/database.js +++ b/database.js @@ -1,4 +1,5 @@ import defineRoleEmojiPair from './models/roleEmojiPair.js'; +import defineVoiceChannel from './models/voiceChannel.js'; import defineMessage from './models/message.js'; import { Sequelize } from 'sequelize'; import { config } from 'dotenv'; @@ -12,8 +13,9 @@ const sequelize = new Sequelize(DB_NAME, DB_USER, DB_PWD, { host: DB_HOST, }); const RoleEmojiPair = defineRoleEmojiPair(sequelize); +const VoiceChannel = defineVoiceChannel(sequelize); const Message = defineMessage(sequelize); sequelize.sync(); -export { sequelize, RoleEmojiPair, Message }; +export { sequelize, RoleEmojiPair, VoiceChannel, Message }; diff --git a/models/voiceChannel.js b/models/voiceChannel.js new file mode 100644 index 0000000..6fb9f41 --- /dev/null +++ b/models/voiceChannel.js @@ -0,0 +1,10 @@ +import { DataTypes } from "sequelize"; + +export default function(sequelize) { + return sequelize.define('VoiceChannel', { + id: { + type: DataTypes.STRING, + primaryKey: true, + }, + }); +}