summary refs log tree commit diff
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-08-07 10:36:42 +0200
committerGitHub <noreply@github.com>2021-08-07 10:36:42 +0200
commit6ff334be3b4464fdc67b547ce0ec6831787812cb (patch)
tree3bb3507b6900e8c4e0d5ee6a9fe2d3c0f5894d12
parentMerge pull request #11 from BanTheNons/publicuserprojection-bio (diff)
parentadded accent_color to the user schema (diff)
downloadserver-6ff334be3b4464fdc67b547ce0ec6831787812cb.tar.xz
Merge pull request #12 from BanTheNons/publicuserprojection-bot
Added bot to PublicUserProjection and implemented user banner colors
-rw-r--r--src/models/User.ts6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/models/User.ts b/src/models/User.ts

index d4893e14..281c14e6 100644 --- a/src/models/User.ts +++ b/src/models/User.ts
@@ -10,7 +10,9 @@ export const PublicUserProjection = { id: true, public_flags: true, avatar: true, + accent_color: true, bio: true, + bot: true, }; export interface User { @@ -18,6 +20,7 @@ export interface User { username: string; // username max length 32, min 2 discriminator: string; // #0001 4 digit long string from #0001 - #9999 avatar: string | null; // hash of the user avatar + accent_color: number | null; // banner color of user phone: string | null; // phone number of the user desktop: boolean; // if the user has desktop app installed mobile: boolean; // if the user has mobile app installed @@ -63,7 +66,9 @@ export interface PublicUser { discriminator: string; username: string; avatar: string | null; + accent_color: number; public_flags: bigint; + bot: boolean; } export interface ConnectedAccount { @@ -141,6 +146,7 @@ export const UserSchema = new Schema({ username: String, discriminator: String, avatar: String, + accent_color: Number, phone: String, desktop: Boolean, mobile: Boolean,