summary refs log tree commit diff
path: root/cdn
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-09-25 23:55:19 +0200
committerFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-09-25 23:55:19 +0200
commit4b2e93c84bb65a051a99ddd663518714ba5ed2cf (patch)
tree71f0a88735c4c91a7963db0ab83ac7de9e382478 /cdn
parent:bug: message attachment url (diff)
downloadserver-4b2e93c84bb65a051a99ddd663518714ba5ed2cf.tar.xz
:sparkles: add private and public endpoint
Diffstat (limited to 'cdn')
-rw-r--r--cdn/src/routes/avatars.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/cdn/src/routes/avatars.ts b/cdn/src/routes/avatars.ts
index 3d745f90..93045925 100644
--- a/cdn/src/routes/avatars.ts
+++ b/cdn/src/routes/avatars.ts
@@ -44,7 +44,8 @@ router.post(
 		if (ANIMATED_MIME_TYPES.includes(type.mime)) hash = `a_${hash}`; // animated icons have a_ infront of the hash
 
 		const path = `avatars/${user_id}/${hash}`;
-		const endpoint = Config.get().cdn.endpoint || "http://localhost:3003";
+		const endpoint =
+			Config.get().cdn.endpointPublic || "http://localhost:3003";
 
 		await storage.set(path, buffer);