summaryrefslogtreecommitdiff
path: root/src/server/api
diff options
context:
space:
mode:
authorMeiMei <30769358+mei23@users.noreply.github.com>2020-08-29 08:56:32 +0900
committerGitHub <noreply@github.com>2020-08-29 08:56:32 +0900
commitc2d7929391d18072b46e6f829c956fd8d99e4b80 (patch)
tree6237d96b196909044ab85d8aa6948d68931926fe /src/server/api
parentUpdate create-notification.ts (diff)
downloadsharkey-c2d7929391d18072b46e6f829c956fd8d99e4b80.tar.gz
sharkey-c2d7929391d18072b46e6f829c956fd8d99e4b80.tar.bz2
sharkey-c2d7929391d18072b46e6f829c956fd8d99e4b80.zip
Expose proxyAccountName (#6670)
Diffstat (limited to 'src/server/api')
-rw-r--r--src/server/api/endpoints/meta.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/server/api/endpoints/meta.ts b/src/server/api/endpoints/meta.ts
index f011a6751f..f46139aa23 100644
--- a/src/server/api/endpoints/meta.ts
+++ b/src/server/api/endpoints/meta.ts
@@ -99,6 +99,8 @@ export default define(meta, async (ps, me) => {
}
});
+ const proxyAccount = instance.proxyAccountId ? await Users.pack(instance.proxyAccountId).catch(() => null) : null;
+
const response: any = {
maintainerName: instance.maintainerName,
maintainerEmail: instance.maintainerEmail,
@@ -143,6 +145,8 @@ export default define(meta, async (ps, me) => {
enableDiscordIntegration: instance.enableDiscordIntegration,
enableServiceWorker: instance.enableServiceWorker,
+
+ proxyAccountName: proxyAccount ? proxyAccount.username : null,
};
if (ps.detail) {