2019-09-13 20:02:41 +00:00
|
|
|
// database stuff
|
2019-10-28 20:21:06 +00:00
|
|
|
const mongoose = require("mongoose");
|
2019-11-13 00:09:06 +00:00
|
|
|
mongoose.connect(process.env.MONGO);
|
2019-10-28 20:21:06 +00:00
|
|
|
const guildSchema = new mongoose.Schema({
|
|
|
|
id: String,
|
|
|
|
tags: Map,
|
|
|
|
prefix: String
|
|
|
|
});
|
|
|
|
const Guild = mongoose.model("Guild", guildSchema);
|
2019-11-05 15:52:46 +00:00
|
|
|
|
|
|
|
const xpSchema = new mongoose.Schema({
|
|
|
|
id: String,
|
|
|
|
members: Map,
|
|
|
|
enabled: Boolean
|
|
|
|
});
|
|
|
|
const XP = mongoose.model("XP", xpSchema);
|
2019-11-13 00:09:06 +00:00
|
|
|
|
2019-11-18 01:57:12 +00:00
|
|
|
const tweetSchema = new mongoose.Schema({
|
|
|
|
tweets: [String],
|
|
|
|
replies: [String],
|
|
|
|
media: [String],
|
|
|
|
phrases: [String],
|
|
|
|
games: [String],
|
|
|
|
characters: [String],
|
2019-11-23 23:23:28 +00:00
|
|
|
download: [String],
|
2019-11-18 01:57:12 +00:00
|
|
|
enabled: Boolean
|
|
|
|
});
|
|
|
|
const TweetCollection = mongoose.model("TweetCollection", tweetSchema);
|
|
|
|
|
2019-11-05 15:52:46 +00:00
|
|
|
exports.guilds = Guild;
|
2019-11-18 01:57:12 +00:00
|
|
|
exports.xp = XP;
|
|
|
|
exports.tweets = TweetCollection;
|