summary refs log tree commit diff
path: root/src/api
diff options
context:
space:
mode:
authorMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2023-01-02 20:37:25 +1100
committerGitHub <noreply@github.com>2023-01-02 20:37:25 +1100
commit5ef4b80fc54db92467961ee8190f1fc93e8b4b71 (patch)
tree5165a3937f8204bf68829aaa6d829481a6693541 /src/api
parentUse adjusted email in /auth/login (diff)
parentProfile themes and pronouns (diff)
downloadserver-5ef4b80fc54db92467961ee8190f1fc93e8b4b71.tar.xz
Merge pull request #922 from MaddyUnderStars/maddy/bodyParserPatch
Patch body-parser to use json-bigint, like gateway
Diffstat (limited to 'src/api')
-rw-r--r--src/api/routes/users/#id/profile.ts10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/api/routes/users/#id/profile.ts b/src/api/routes/users/#id/profile.ts
index 083d44af..ac844427 100644
--- a/src/api/routes/users/#id/profile.ts
+++ b/src/api/routes/users/#id/profile.ts
@@ -92,7 +92,9 @@ router.get(
 	const userProfile = {
 		bio: req.user_bot ? null : user.bio,
 		accent_color: user.accent_color,
-		banner: user.banner
+		banner: user.banner,
+		pronouns: user.pronouns,
+		theme_colors: user.theme_colors,
 	};
 
 	const guildMemberDto = guild_member
@@ -126,6 +128,8 @@ router.get(
 		premium_since: user.premium_since, // TODO
 		mutual_guilds: mutual_guilds, // TODO {id: "", nick: null} when ?with_mutual_guilds=true
 		user: userDto,
+		premium_type: user.premium_type,
+		profile_themes_experiment_bucket: 4,	// TODO: This doesn't make it available, for some reason?
 		user_profile: userProfile,
 		guild_member: guild_id && guildMemberDto,
 		guild_member_profile: guild_id && guildMemberProfile
@@ -154,7 +158,9 @@ router.patch("/", route({ body: "UserProfileModifySchema" }), async (req: Reques
 	res.json({
 		accent_color: user.accent_color,
 		bio: user.bio,
-		banner: user.banner
+		banner: user.banner,
+		theme_colors: user.theme_colors,
+		pronouns: user.pronouns,
 	});
 });