summary refs log tree commit diff
path: root/dist/models/Guild.js
diff options
context:
space:
mode:
authorafeuerstein <32029275+afeuerstein@users.noreply.github.com>2021-04-06 21:32:44 +0200
committerafeuerstein <32029275+afeuerstein@users.noreply.github.com>2021-04-06 21:32:44 +0200
commit0e8356e9b1acd95be5b94f0e55bba9d749a36d12 (patch)
tree628a02e478cf8df2b4c12eab14bfb7f1dac03be2 /dist/models/Guild.js
parent:bug: fix Message Model (diff)
downloadserver-0e8356e9b1acd95be5b94f0e55bba9d749a36d12.tar.xz
remove compiled typescript code from repo
Diffstat (limited to 'dist/models/Guild.js')
-rw-r--r--dist/models/Guild.js87
1 files changed, 0 insertions, 87 deletions
diff --git a/dist/models/Guild.js b/dist/models/Guild.js
deleted file mode 100644
index fa87d542..00000000
--- a/dist/models/Guild.js
+++ /dev/null
@@ -1,87 +0,0 @@
-"use strict";
-var __importDefault = (this && this.__importDefault) || function (mod) {
-    return (mod && mod.__esModule) ? mod : { "default": mod };
-};
-Object.defineProperty(exports, "__esModule", { value: true });
-exports.GuildModel = exports.GuildSchema = void 0;
-const mongoose_1 = require("mongoose");
-const Database_1 = __importDefault(require("../util/Database"));
-const Channel_1 = require("./Channel");
-const Emoji_1 = require("./Emoji");
-const Member_1 = require("./Member");
-const Role_1 = require("./Role");
-exports.GuildSchema = new mongoose_1.Schema({
-    id: { type: String, required: true },
-    afk_channel_id: String,
-    afk_timeout: Number,
-    application_id: String,
-    banner: String,
-    default_message_notifications: Number,
-    description: String,
-    discovery_splash: String,
-    explicit_content_filter: Number,
-    features: { type: [String], default: [] },
-    icon: String,
-    large: Boolean,
-    max_members: { type: Number, default: 100000 },
-    max_presences: Number,
-    max_video_channel_users: { type: Number, default: 25 },
-    member_count: Number,
-    presence_count: Number,
-    mfa_level: Number,
-    name: { type: String, required: true },
-    owner_id: { type: String, required: true },
-    preferred_locale: String,
-    premium_subscription_count: Number,
-    premium_tier: Number,
-    public_updates_channel_id: String,
-    region: String,
-    rules_channel_id: String,
-    splash: String,
-    system_channel_flags: Number,
-    system_channel_id: String,
-    unavailable: Boolean,
-    vanity_url_code: String,
-    verification_level: Number,
-    voice_states: { type: [Object], default: [] },
-    welcome_screen: { type: [Object], default: [] },
-    widget_channel_id: String,
-    widget_enabled: Boolean,
-});
-exports.GuildSchema.virtual("channels", {
-    ref: Channel_1.ChannelModel,
-    localField: "id",
-    foreignField: "guild_id",
-    justOne: false,
-});
-exports.GuildSchema.virtual("roles", {
-    ref: Role_1.RoleModel,
-    localField: "id",
-    foreignField: "guild_id",
-    justOne: false,
-});
-// nested populate is needed for member users: https://gist.github.com/yangsu/5312204
-exports.GuildSchema.virtual("members", {
-    ref: Member_1.MemberModel,
-    localField: "id",
-    foreignField: "member_id",
-    justOne: false,
-});
-exports.GuildSchema.virtual("emojis", {
-    ref: Emoji_1.EmojiModel,
-    localField: "id",
-    foreignField: "guild_id",
-    justOne: false,
-});
-exports.GuildSchema.virtual("joined_at", {
-    ref: Member_1.MemberModel,
-    localField: "id",
-    foreignField: "guild_id",
-    justOne: true,
-}).get((member, virtual, doc) => {
-    console.log("get", member, this);
-    return member.joined_at;
-});
-// @ts-ignore
-exports.GuildModel = Database_1.default.model("Guild", exports.GuildSchema, "guilds");
-//# sourceMappingURL=Guild.js.map
\ No newline at end of file